Hi here,
For Linux desktop login, say, Gnome, with the bash as the default shell, is there a method to save all the detailed sourced files information and the errors during the logging process?
I often encounter strange phenomena and problems in login, but I don't know where they come from. Any tips will be appreciated.
On Wed, 25 Jan 2023 20:28:31 -0800 (PST), hongy...@gmail.com wrote:
Hi here,
For Linux desktop login, say, Gnome, with the bash as the default shell, is there a method to save all the detailed sourced files information and the errors during the logging process?
I often encounter strange phenomena and problems in login, but I don't know where they come from. Any tips will be appreciated.Since you did not provide what Distribution you are using, no one can a
lot of detailed information.
So, check system logs, X11 logs, and user logs.
Since I am running Xfce4 on Mageia Linux that would be journalctl, /var/log. and ~/.*error*
werner@X10DAi:~$ ls /etc/profile.d/000-rootshare.sh >/etc/profile.d/000-rootshare.sh[...]
werner@X10DAi:~$ ls ~/.profile.d/
000-networkd-resolved-netplan-dnsmasq.bash 300-fcitx5-rime.bash >001-dnsmasq-dnsproxy.bash 300-firefox.bash
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), "hongy...@gmail.com" <hongy...@gmail.com> wrote:
[...]
werner@X10DAi:~$ ls /etc/profile.d/000-rootshare.sh >/etc/profile.d/000-rootshare.sh[...]
werner@X10DAi:~$ ls ~/.profile.d/ >000-networkd-resolved-netplan-dnsmasq.bash 300-fcitx5-rime.bash >001-dnsmasq-dnsproxy.bash 300-firefox.bash
Binay search will take just a few tries.
Move half of the scripts in ~/.profile.d/ somewhere where they
will not run.
Try again.
- No error: the problem was in the half you moved away
- Still error: the problem was in the half you did not move
Proceed by activating half of the set of scripts that has the
problem.
Repeat until the size of the set is one script.
--
Kees Nuyt
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and stillfailed to figure out the solution.
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:failed to figure out the solution.
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and still
I suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem. If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
Do you mean always first test any newly added/revised script with this account?
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
[...]
Do you mean always first test any newly added/revised script with this account?
Best,
Zhao
On Thu, 26 Jan 2023 19:09:46 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
Do you mean always first test any newly added/revised script with this account?Why not. Can not see that it take long to su -l junk and enter password.
On my distribution, that kind of error will not let you do a gui login.
What is your procedure if you make a change and can not do a gui login?
On Friday, January 27, 2023 at 11:16:01 AM UTC+8, Bit Twister wrote:
On Thu, 26 Jan 2023 19:09:46 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:Why not. Can not see that it take long to su -l junk and enter password.
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
Do you mean always first test any newly added/revised script with this
account?
Agreed.
On my distribution, that kind of error will not let you do a gui login.
That's the same dilemma I face here.
What is your procedure if you make a change and can not do a gui login?
Fortunately, I found the following quick workaround to avoid rebooting the system for the next login attempt when the "Are you sure you want to proceed?" problem occurs:
1. Ctrl + Alt + F4 opens a console window, where you can log in using the username and password.
2. After logging in, run the following command to restart gdm:
$ sudo systemctl restart gdm
3. Then you will have the opportunity to log back in to the GUI.
On Fri, 27 Jan 2023 00:35:24 -0800 (PST), hongy...@gmail.com wrote:
On Friday, January 27, 2023 at 11:16:01 AM UTC+8, Bit Twister wrote:
On Thu, 26 Jan 2023 19:09:46 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:Why not. Can not see that it take long to su -l junk and enter password.
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
Do you mean always first test any newly added/revised script with this >> > account?
Agreed.
On my distribution, that kind of error will not let you do a gui login.
That's the same dilemma I face here.
What is your procedure if you make a change and can not do a gui login?
Fortunately, I found the following quick workaround to avoid rebooting the system for the next login attempt when the "Are you sure you want to proceed?" problem occurs:
1. Ctrl + Alt + F4 opens a console window, where you can log in using the username and password.
2. After logging in, run the following command to restart gdm:
$ sudo systemctl restart gdm
3. Then you will have the opportunity to log back in to the GUI.But what happens if gui does not start.
Can YOU run a non gui editor to rectify your induced problem?
On Friday, January 27, 2023 at 6:50:08 PM UTC+8, Bit Twister wrote:
Can YOU run a non gui editor to rectify your induced problem?
Only if I know what's the culprit, otherwise, I don't know what should be rectified, just as the question discussed here.
On Fri, 27 Jan 2023 06:14:53 -0800 (PST), hongy...@gmail.com wrote:
On Friday, January 27, 2023 at 6:50:08 PM UTC+8, Bit Twister wrote:
Can YOU run a non gui editor to rectify your induced problem?
Only if I know what's the culprit, otherwise, I don't know what should be rectified, just as the question discussed here.If you are modifying one of your files in the login path, I assume you have set -u
just after the #!/bin/bash at the top of your scripts, I would expect when you do a su - l junk you will see some bash error message.
The quest was not about what file, but can YOU run a non-gui editor?
On Thu, 26 Jan 2023 19:09:46 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
Do you mean always first test any newly added/revised script with this
account?
Why not. Can not see that it take long to su -l junk and enter password.
On my distribution, that kind of error will not let you do a gui login.
What is your procedure if you make a change and can not do a gui login?
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), "hongy...@gmail.com" <hongy...@gmail.com> wrote:
[...]
werner@X10DAi:~$ ls /etc/profile.d/000-rootshare.sh >/etc/profile.d/000-rootshare.sh[...]
werner@X10DAi:~$ ls ~/.profile.d/ >000-networkd-resolved-netplan-dnsmasq.bash 300-fcitx5-rime.bash >001-dnsmasq-dnsproxy.bash 300-firefox.bash
Binay search will take just a few tries.
Move half of the scripts in ~/.profile.d/ somewhere where they
will not run.
Try again.
- No error: the problem was in the half you moved away
- Still error: the problem was in the half you did not move
Proceed by activating half of the set of scripts that has the
problem.
Repeat until the size of the set is one script.
--Zhao
Kees Nuyt
I've tried out the above method, and find that the
"Are you sure you want to proceed?" problem is not
caused by any scripts located under ~/.profile.d/. So
what should I do for further examination?
On Sun, 29 Jan 2023 17:34:18 -0800 (PST), "hongy...@gmail.com" <hongy...@gmail.com> wrote:
I've tried out the above method, and find that theContinue with the scripts in /etc/profile.d/ , and
"Are you sure you want to proceed?" problem is not
caused by any scripts located under ~/.profile.d/. So
what should I do for further examination?
and ~/.xxxxxx scripts, like .bashrc and .profile,
and any GUI equivalents of those.
--Zhao
Kees Nuyt
On Thursday, January 26, 2023 at 8:12:15 PM UTC+8, Kees Nuyt wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), "hongy...@gmail.com" <hongy...@gmail.com> wrote:
[...]
werner@X10DAi:~$ ls /etc/profile.d/000-rootshare.sh >/etc/profile.d/000-rootshare.sh[...]
werner@X10DAi:~$ ls ~/.profile.d/ >000-networkd-resolved-netplan-dnsmasq.bash 300-fcitx5-rime.bash >001-dnsmasq-dnsproxy.bash 300-firefox.bash
Binay search will take just a few tries.
Move half of the scripts in ~/.profile.d/ somewhere where they
will not run.
Try again.
- No error: the problem was in the half you moved away
- Still error: the problem was in the half you did not move
Proceed by activating half of the set of scripts that has theI've tried out the above method, and find that the "Are you sure you want to proceed?" problem is not caused by any scripts located under ~/.profile.d/. So what should I do for further examination?
problem.
Repeat until the size of the set is one script.
--Zhao
Kees Nuyt
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:failed to figure out the solution.
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and still
I suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem. If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
Finally, it turns out that the problem is caused by a bug
of a Ubuntu patch and the incorrect settings in my
initialization scripts.
On Sun, 5 Feb 2023 03:41:22 -0800 (PST), "hongy...@gmail.com" <hongy...@gmail.com> wrote:
Finally, it turns out that the problem is caused by a bugI'm glad you could solve it.
of a Ubuntu patch and the incorrect settings in my
initialization scripts.
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:failed to figure out the solution.
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and still
I suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem. >> If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
According to the above suggestions, I conducted the following test:
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234
werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again: werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more:
test@X10DAi:~$ su - werner
Password:
terminate called after throwing an instance of 'std::runtime_error'
what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
On Mon, 6 Feb 2023 01:40:42 -0800 (PST), hongy...@gmail.com wrote:still failed to figure out the solution.
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and
I suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem.
If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
According to the above suggestions, I conducted the following test:
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234 werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again: werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more:
test@X10DAi:~$ su - wernerif su - test works and su - werner failed
Password:
terminate called after throwing an instance of 'std::runtime_error' what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
then some script executed by werner login is failing.
No idea why
Message about dirname and readlink aught to be fixed.
Apparently you are running some script executing those instructions that test does not execute.
By the way, after spending years as an maintenance programmer I found it beneficial
to fix any errors I find even if I believe they have no bearing on the problem
I am trying to fix.
For your xhost problem I would need to see the xhost command. Looking through my
host xx__local.sh script I have
# grep xhost xx__local.sh
/local/bin/set_xhost +"$(hostname --fqdn)"
/local/bin/set_xhost +localhost >
xhost +local:docker
You may want to consider install/using shellcheck to check your scripts.
On Mon, 6 Feb 2023 01:40:42 -0800 (PST), hongy...@gmail.com wrote:still failed to figure out the solution.
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and
I suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem.
If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
According to the above suggestions, I conducted the following test:
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234 werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again: werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more:
test@X10DAi:~$ su - wernerif su - test works and su - werner failed
Password:
terminate called after throwing an instance of 'std::runtime_error' what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
then some script executed by werner login is failing.
No idea why
Message about dirname and readlink aught to be fixed.
Apparently you are running some script executing those instructions that test does not execute.
By the way, after spending years as an maintenance programmer I found it beneficial
to fix any errors I find even if I believe they have no bearing on the problem
I am trying to fix.
For your xhost problem I would need to see the xhost command. Looking through my
host xx__local.sh script I have
# grep xhost xx__local.sh
/local/bin/set_xhost +"$(hostname --fqdn)"
/local/bin/set_xhost +localhost >
xhost +local:docker
You may want to consider install/using shellcheck to check your scripts.
On Wednesday, February 8, 2023 at 10:25:47 AM UTC+8, Bit Twister wrote:still failed to figure out the solution.
On Mon, 6 Feb 2023 01:40:42 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and
if su - test works and su - werner failedI suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem.
If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
According to the above suggestions, I conducted the following test:
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234
werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test
werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again:
werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more: >> >
test@X10DAi:~$ su - werner
Password:
terminate called after throwing an instance of 'std::runtime_error'
what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
then some script executed by werner login is failing.
No idea why
Message about dirname and readlink aught to be fixed.
Apparently you are running some script executing those instructions that
test does not execute.
By the way, after spending years as an maintenance programmer I found it beneficial
to fix any errors I find even if I believe they have no bearing on the problem
I am trying to fix.
For your xhost problem I would need to see the xhost command. Looking through my
host xx__local.sh script I have
# grep xhost xx__local.sh
/local/bin/set_xhost +"$(hostname --fqdn)"
/local/bin/set_xhost +localhost >
xhost +local:docker
You may want to consider install/using shellcheck to check your scripts.
I wonder whether there is a similar but targeting for generating detail debug messages of startup scripts (profile, .bashrc, etc...).
On Tue, 7 Feb 2023 22:27:14 -0800 (PST), hongy...@gmail.com wrote:still failed to figure out the solution.
On Wednesday, February 8, 2023 at 10:25:47 AM UTC+8, Bit Twister wrote:
On Mon, 6 Feb 2023 01:40:42 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote: >> >> On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in and
if su - test works and su - werner failedI suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem.
If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the >> >> other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending >> >> on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
According to the above suggestions, I conducted the following test:
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234
werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test
werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again:
werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more:
test@X10DAi:~$ su - werner
Password:
terminate called after throwing an instance of 'std::runtime_error'
what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
then some script executed by werner login is failing.
No idea why
Message about dirname and readlink aught to be fixed.
Apparently you are running some script executing those instructions that >> test does not execute.
By the way, after spending years as an maintenance programmer I found it beneficial
to fix any errors I find even if I believe they have no bearing on the problem
I am trying to fix.
For your xhost problem I would need to see the xhost command. Looking through my
host xx__local.sh script I have
# grep xhost xx__local.sh
/local/bin/set_xhost +"$(hostname --fqdn)"
/local/bin/set_xhost +localhost >
xhost +local:docker
You may want to consider install/using shellcheck to check your scripts.
I wonder whether there is a similar but targeting for generating detail debug messages of startup scripts (profile, .bashrc, etc...).For debugging a script I use
script -c "bash -x script_to_debug_here" a.log
As for login scripts which I need to see when something changed modified /etc/profile to check if $HOME/debug is executable and if so run it.
Test is before/after each login script. Example snippet from /etc/profile follows"
for i in /etc/profile.d/*.sh /etc/profile.d/sh.local ; do
if [ -r "$i" ]; then
if [ "${-#*i}" != "$-" ]; then
if [ -x $HOME/debug ] ; then
. $HOME/debug "starting $i "
fi
. "$i"
if [ -x $HOME/debug ] ; then
. $HOME/debug "finished $i "
fi
else
if [ -x $HOME/debug ] ; then
. $HOME/debug "starting $i "
fi
. "$i" >/dev/null
if [ -x $HOME/debug ] ; then
. $HOME/debug "finished $i "
fi
fi
fi
done
On Friday, February 17, 2023 at 8:00:53 PM UTC+8, Bit Twister wrote:and still failed to figure out the solution.
On Tue, 7 Feb 2023 22:27:14 -0800 (PST), hongy...@gmail.com wrote:
On Wednesday, February 8, 2023 at 10:25:47 AM UTC+8, Bit Twister wrote:
On Mon, 6 Feb 2023 01:40:42 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote: >> >> On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote: >> >>
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in
if su - test works and su - werner failedI suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem.
If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to
su - junk and very there are no problems.
According to the above suggestions, I conducted the following test: >> >
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234
werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test
werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again:
werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more:
test@X10DAi:~$ su - werner
Password:
terminate called after throwing an instance of 'std::runtime_error' >> > what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
then some script executed by werner login is failing.
No idea why
Message about dirname and readlink aught to be fixed.
Apparently you are running some script executing those instructions that
test does not execute.
By the way, after spending years as an maintenance programmer I found it beneficial
to fix any errors I find even if I believe they have no bearing on the problem
I am trying to fix.
For your xhost problem I would need to see the xhost command. Looking through my
host xx__local.sh script I have
# grep xhost xx__local.sh
/local/bin/set_xhost +"$(hostname --fqdn)"
/local/bin/set_xhost +localhost >
xhost +local:docker
You may want to consider install/using shellcheck to check your scripts.
I wonder whether there is a similar but targeting for generating detail debug messages of startup scripts (profile, .bashrc, etc...).For debugging a script I use
script -c "bash -x script_to_debug_here" a.log
As for login scripts which I need to see when something changed modified /etc/profile to check if $HOME/debug is executable and if so run it.
Test is before/after each login script. Example snippet from /etc/profile follows"
feeeeresrsdrdcvfor i in /etc/profile.d/*.sh /etc/profile.d/sh.local ; doNice idea. Thank you very much again. I will try to follow your prompts for further inspection and testing.
if [ -r "$i" ]; then
if [ "${-#*i}" != "$-" ]; then
if [ -x $HOME/debug ] ; then
. $HOME/debug "starting $i "
fi
. "$i"
if [ -x $HOME/debug ] ; then
. $HOME/debug "finished $i "
fi
else
if [ -x $HOME/debug ] ; then
. $HOME/debug "starting $i "
fi
. "$i" >/dev/null
if [ -x $HOME/debug ] ; then
. $HOME/debug "finished $i "
fi
fi
fi
done
Regards,
Zhao
On Saturday, February 25, 2023 at 9:41:06 AM UTC-6, hongy...@gmail.com wrote:and still failed to figure out the solution.
On Friday, February 17, 2023 at 8:00:53 PM UTC+8, Bit Twister wrote:
On Tue, 7 Feb 2023 22:27:14 -0800 (PST), hongy...@gmail.com wrote:
On Wednesday, February 8, 2023 at 10:25:47 AM UTC+8, Bit Twister wrote:
On Mon, 6 Feb 2023 01:40:42 -0800 (PST), hongy...@gmail.com wrote:
On Thursday, January 26, 2023 at 9:52:05 PM UTC+8, Bit Twister wrote:
On Wed, 25 Jan 2023 23:17:06 -0800 (PST), hongy...@gmail.com wrote:
Recently, I always meet the "Are you sure you want to proceed?" message on login as described here [1], and none of the above logs give me some clues. I want to disable the above message window to appear each time when I'm trying to log in
if su - test works and su - werner failedI suggest creating a test account, say junk. Log out of hongyi and into junk.
If junk has the same problem as hongyi you know it is a system wide problem.
If junk does not have the problem then you know it is a user (hongyi) problem.
You can test the login process from either account by logging into the
other user account by clicking up a terminal and doing
su - junk
from a hongyi terminal or su - hongyi from a junk terminal, depending
on who you want to test.
For you, I suggest anytime you make any login script change is to >> >> su - junk and very there are no problems.
According to the above suggestions, I conducted the following test: >> >
werner@X10DAi:~$ sudo useradd test
werner@X10DAi:~$ sudo passwd test # Set the pw as: asdf1234
werner@X10DAi:~$ sudo usermod -d /home/test -s /bin/bash test
werner@X10DAi:~$ sudo mkdir /home/test
# This time, the problem discussed here doesn't appear again:
werner@X10DAi:~$ su - test
Password:
test@X10DAi:~$
So, I tried to login back as follows and the problem appeared once more:
test@X10DAi:~$ su - werner
Password:
terminate called after throwing an instance of 'std::runtime_error' >> > what(): Failed to create dbus connection
xhost: unable to open display ""
dirname: invalid option -- 'b'
Try 'dirname --help' for more information.
readlink: invalid option -- 'b'
Try 'readlink --help' for more information.
su - werner
Any tips for further debugging?
then some script executed by werner login is failing.
No idea why
Message about dirname and readlink aught to be fixed.
Apparently you are running some script executing those instructions that
test does not execute.
By the way, after spending years as an maintenance programmer I found it beneficial
to fix any errors I find even if I believe they have no bearing on the problem
I am trying to fix.
For your xhost problem I would need to see the xhost command. Looking through my
host xx__local.sh script I have
# grep xhost xx__local.sh
/local/bin/set_xhost +"$(hostname --fqdn)"
/local/bin/set_xhost +localhost >
xhost +local:docker
You may want to consider install/using shellcheck to check your scripts.
I wonder whether there is a similar but targeting for generating detail debug messages of startup scripts (profile, .bashrc, etc...).For debugging a script I use
script -c "bash -x script_to_debug_here" a.log
As for login scripts which I need to see when something changed modified /etc/profile to check if $HOME/debug is executable and if so run it. Test is before/after each login script. Example snippet from /etc/profile
follows"
for i in /etc/profile.d/*.sh /etc/profile.d/sh.local ; doNice idea. Thank you very much again. I will try to follow your prompts for further inspection and testing.
if [ -r "$i" ]; then
if [ "${-#*i}" != "$-" ]; then
if [ -x $HOME/debug ] ; then
. $HOME/debug "starting $i "
fi
. "$i"
if [ -x $HOME/debug ] ; then
. $HOME/debug "finished $i "
fi
else
if [ -x $HOME/debug ] ; then
. $HOME/debug "starting $i "
fi
. "$i" >/dev/null
if [ -x $HOME/debug ] ; then
. $HOME/debug "finished $i "
fi
fi
fi
done
Regards,feeeeresrsdrdcv
Zhao
Hi here,
For Linux desktop login, say, Gnome, with the bash as the default shell, is there a method to save all the detailed sourced files information and the errors during the logging process?
I often encounter strange phenomena and problems in login, but I don't know where they come from. Any tips will be appreciated.
Regards,
Zhaorffrfrrfrfrfrfrfrfrffrfr
On Wednesday, January 25, 2023 at 10:28:34 PM UTC-6, hongy...@gmail.com wrote:
Hi here,
For Linux desktop login, say, Gnome, with the bash as the default shell, is there a method to save all the detailed sourced files information and the errors during the logging process?
I often encounter strange phenomena and problems in login, but I don't know where they come from. Any tips will be appreciated.
Regards,
Zhaorffrfrrfrfrfrfrfrfrffrfr
Hi here,gttttfftftftfggyygytytyttggggttggttgtgtgt66666666676ttyyyuy
For Linux desktop login, say, Gnome, with the bash as the default shell, is there a method to save all the detailed sourced files information and the errors during the logging process?
I often encounter strange phenomena and problems in login, but I don't know where they come from. Any tips will be appreciated.
Regards,
Zhao
Hi here,fffdtdfdfrrrdrdtdtttffrfrf
For Linux desktop login, say, Gnome, with the bash as the default shell, is there a method to save all the detailed sourced files information and the errors during the logging process?
I often encounter strange phenomena and problems in login, but I don't know where they come from. Any tips will be appreciated.
Regards,
Zhao
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 498 |
Nodes: | 16 (2 / 14) |
Uptime: | 45:48:33 |
Calls: | 9,800 |
Calls today: | 2 |
Files: | 13,752 |
Messages: | 6,189,887 |