Hello,
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
Thank
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 | | Room# D114A ===========================================================================
On Thu, 21 Jul 2022 16:48:57 +0200 Patrick Dupre pdupre@gmx.com wrote:
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
I haven't actually tried this since all my systems so far have had a root account, but sudo useradd -u 1 -p throwawaypassword root should do the trick. Then run sudo passwd --expire root so that root will have to change their password on the first login. Then immediately login as root and set the root password to what you want.
There is a possible security hole here if you are on a system with multiple users, since someone could see that the root account has been created, set to expired, login, and have root access. Unlikely.
See man pages for useradd, usermod, and passwd.
On 7/21/22 12:18, stan via users wrote:
There is a possible security hole here if you are on a system with multiple users, since someone could see that the root account has been created, set to expired, login, and have root access. Unlikely.
That's not a problem if you do it right. As soon as you've created the account, use su (or su -) to log in and change the password.
On 7/21/22 11:18, stan via users wrote:
On Thu, 21 Jul 2022 16:48:57 +0200 Patrick Dupre pdupre@gmx.com wrote:
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
I haven't actually tried this since all my systems so far have had a root account, but sudo useradd -u 1 -p throwawaypassword root should do the trick. Then run sudo passwd --expire root so that root will have to change their password on the first login. Then immediately login as root and set the root password to what you want.
I don't understand how this is an answer to the question. There is always a root account, you can't create one. I think he just wants it to run ".bashrc" at login which it isn't (?) for some reason.
On 7/21/22 13:19, Samuel Sieb wrote:
I don't understand how this is an answer to the question. There is always a root account, you can't create one. I think he just wants it to run ".bashrc" at login which it isn't (?) for some reason.
It's possible that he's using su, not su -. The first simply changes your userid to 0, while the second does a complete login, including running root's .bashrc and changing your pwd to /root.
On Thu, 21 Jul 2022 12:19:37 -0700 Samuel Sieb samuel@sieb.net wrote:
On 7/21/22 11:18, stan via users wrote:
On Thu, 21 Jul 2022 16:48:57 +0200 Patrick Dupre pdupre@gmx.com wrote:
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
I haven't actually tried this since all my systems so far have had a root account, but sudo useradd -u 1 -p throwawaypassword root should do the trick. Then run sudo passwd --expire root so that root will have to change their password on the first login. Then immediately login as root and set the root password to what you want.
I don't understand how this is an answer to the question. There is always a root account, you can't create one. I think he just wants it to run ".bashrc" at login which it isn't (?) for some reason.
As I said, I haven't actually experienced one of the new setups without root login. passwd --status root If the /root directory is present and root is already assigned to UID 1, then it should only be necessary to remove the lock on the password and set up a password. passwd --unlock --expire root
On 7/22/22 08:12, stan via users wrote:
passwd --unlock --expire root
Hi Stan,
Why did you throw --expire on the above command?
-e, --expire This is a quick way to expire a password for an account. The user will be forced to change the password during the next login attempt. Available to root only.
-T
On Fri, 22 Jul 2022 10:04:37 -0700 ToddAndMargo via users users@lists.fedoraproject.org wrote:
On 7/22/22 08:12, stan via users wrote:
passwd --unlock --expire root
Hi Stan,
Why did you throw --expire on the above command?
-e, --expire This is a quick way to expire a password for an account. The user will be forced to change the password during the next login attempt. Available to root only.
If the account has been locked, and never used, there is probably no password. This ensures that the root user, gets to set the password that they want. In fact, they can't access the root account without setting a new password. This doesn't apply to installs that already have an active root user (older installs). The new installs, from what I understand, do not set up a root account password as part of the install process. Everyone is supposed to use sudo, for its apparently increased security, or convenience, or lack of confusion, etc. As I said, I have only read about this, and haven't experienced it, so am not aware of the actual state of the root account when that occurs. Samuel has said the account always exists, so I assume that it must be locked if a login wasn't created during the install.
On Sat, 2022-07-23 at 18:18 -0700, stan via users wrote:
The new installs, from what I understand, do not set up a root account password as part of the install process.
I installed Fedora 36 not long ago, Mate spin. There was an opportunity to set up root while the install was going on.
I always do. It's far more convenient for me to open a terminal and "su -" so I can do a mass of text editing setting up servers, than sudo each thing (*). I don't do graphical logins as root, so I have no idea if that still works.
I might be editing several DNS zone records, a DHCP server config, restarting the servers, checking things worked, stopping servers, doing tweaks, rinse lather repeat. I'm damned if I want to be typing my lengthy password for each instance of that. If I was forced to sudo every one of those, the password would end up being shortened to something easier to type. That's more of a security problem in my book.
On 7/23/22 20:31, Tim via users wrote:
I always do. It's far more convenient for me to open a terminal and "su -" so I can do a mass of text editing setting up servers, than sudo each thing (*). I don't do graphical logins as root, so I have no idea if that still works.
(*) "sudo -i"
Tim via users wrote:
It's far more convenient for me to open a terminal and "su -" so I can do a mass of text editing setting up servers, than sudo each thing (*).
Samuel Sieb:
(*) "sudo -i"
I can't see any tangible difference between doing "su -" and then using the command line as root user to do a pile of things, or starting off by doing "sudo -i" instead (at least not in the Mate terminal).
On Sun, Jul 24, 2022 at 5:59 AM Tim via users users@lists.fedoraproject.org wrote:
Tim via users wrote:
It's far more convenient for me to open a terminal and "su -" so I can do a mass of text editing setting up servers, than sudo each thing (*).
Samuel Sieb:
(*) "sudo -i"
I can't see any tangible difference between doing "su -" and then using the command line as root user to do a pile of things, or starting off by doing "sudo -i" instead (at least not in the Mate terminal).
I used to have a couple shell scripts that did setups for workstations and
servers, so a couple sudo's was all I needed (but each script took long enough that I did have to enter a password each time).
"su -" could be OK if you a) keep good notes, and b) are the only one using su. Sudo is very helpful where there are multiple admins working different hours or remotely, so you can easily determine what the other person did. What would happen if the person using "su -" was riding a bike to work and got squished by a truck?
"sudo" has configuration to allow specific commands for some group, but as a consequence, has an increased footprint for exploits (via bugs or misconfiguration).
"doas" may be better for those who don't actually need sudo features. Both sudo and doas command lines can be viewed in with journalctl, so there is less need to manually make detailed notes.
On 7/24/22 11:52, George N. White III wrote:
"sudo" has configuration to allow specific commands for some group, but as a consequence, has an increased footprint for exploits (via bugs or misconfiguration).
There was a time that I removed sudo from my Fedora installation as redundant, as I always set a root password. Then, over a year later, I had to re-install it because there were (and probably still are) install scripts in .rpms that used it, although for the life of me I can't imagine why; after all, both rpm and dnf need to be run as root to install or remove packages.
On 7/24/22 11:49, Joe Zeff wrote:
On 7/24/22 11:52, George N. White III wrote:
"sudo" has configuration to allow specific commands for some group, but as a consequence, has an increased footprint for exploits (via bugs or misconfiguration).
There was a time that I removed sudo from my Fedora installation as redundant, as I always set a root password. Then, over a year later, I had to re-install it because there were (and probably still are) install scripts in .rpms that used it, although for the life of me I can't imagine why; after all, both rpm and dnf need to be run as root to install or remove packages.
I assume these are 3rd party rpms. If you found something like that in Fedora, you should file a bug.
On Sun, Jul 24, 2022 at 6:14 PM Joe Zeff joe@zeff.us wrote:
On 7/24/22 14:09, Samuel Sieb wrote:
I assume these are 3rd party rpms. If you found something like that in Fedora, you should file a bug.
I doubt it, as I've always tended to stick to the repos. It was years ago, and I don't remember which packages they were.
The bugs were probably fixed "years ago". Enough time has passed to to allow newcomers to make the mistake again. Sudo can be what lawyers call an "attractive nuisance".
On 7/24/22 01:58, Tim via users wrote:
Tim via users wrote:
It's far more convenient for me to open a terminal and "su -" so I can do a mass of text editing setting up servers, than sudo each thing (*).
Samuel Sieb:
(*) "sudo -i"
I can't see any tangible difference between doing "su -" and then using the command line as root user to do a pile of things, or starting off by doing "sudo -i" instead (at least not in the Mate terminal).
The difference is whether or not root has a password or which password you want to enter. But the point was that you mentioned "sudo each thing", so I was just saying that you can do "sudo -i" once and then run all the commands you want.
On 24 Jul 2022, at 09:59, Tim via users users@lists.fedoraproject.org wrote:
Tim via users wrote:
It's far more convenient for me to open a terminal and "su -" so I can do a mass of text editing setting up servers, than sudo each thing (*).
Samuel Sieb:
(*) "sudo -i"
I can't see any tangible difference between doing "su -" and then using the command line as root user to do a pile of things, or starting off by doing "sudo -i" instead (at least not in the Mate terminal).
For sudo -i you need your user password. For su - you need root to have a password set and that you know it.
Barry
--
uname -rsvp Linux 3.10.0-1160.71.1.el7.x86_64 #1 SMP Tue Jun 28 15:37:28 UTC 2022 x86_64
Boilerplate: All unexpected mail to my mailbox is automatically deleted. I will only get to see the messages that are posted to the mailing list.
users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
On 7/23/22 18:18, stan via users wrote:
On Fri, 22 Jul 2022 10:04:37 -0700 ToddAndMargo via users users@lists.fedoraproject.org wrote:
On 7/22/22 08:12, stan via users wrote:
passwd --unlock --expire root
Hi Stan,
Why did you throw --expire on the above command?
-e, --expire This is a quick way to expire a password for an account. The user will be forced to change the password during the next login attempt. Available to root only.
If the account has been locked, and never used, there is probably no password. This ensures that the root user, gets to set the password that they want. In fact, they can't access the root account without setting a new password. This doesn't apply to installs that already have an active root user (older installs). The new installs, from what I understand, do not set up a root account password as part of the install process. Everyone is supposed to use sudo, for its apparently increased security, or convenience, or lack of confusion, etc. As I said, I have only read about this, and haven't experienced it, so am not aware of the actual state of the root account when that occurs. Samuel has said the account always exists, so I assume that it must be locked if a login wasn't created during the install.
Okay, I understand now. I thought your command both unlocked and set the password. And I thought there was some reason you were messing with the guy making him change it the next log in.
On 7/25/22 18:39, ToddAndMargo via users wrote:
On 7/23/22 18:18, stan via users wrote:
On Fri, 22 Jul 2022 10:04:37 -0700 ToddAndMargo via users users@lists.fedoraproject.org wrote:
On 7/22/22 08:12, stan via users wrote:
passwd --unlock --expire root
Hi Stan,
Why did you throw --expire on the above command?
-e, --expire This is a quick way to expire a password for an account. The user will be forced to change the password during the next login attempt. Available to root only.
If the account has been locked, and never used, there is probably no password. This ensures that the root user, gets to set the password that they want. In fact, they can't access the root account without setting a new password. This doesn't apply to installs that already have an active root user (older installs). The new installs, from what I understand, do not set up a root account password as part of the install process. Everyone is supposed to use sudo, for its apparently increased security, or convenience, or lack of confusion, etc. As I said, I have only read about this, and haven't experienced it, so am not aware of the actual state of the root account when that occurs. Samuel has said the account always exists, so I assume that it must be locked if a login wasn't created during the install.
Okay, I understand now. I thought your command both unlocked and set the password. And I thought there was some reason you were messing with the guy making him change it the next log in.
You can't actually run that command ("test" is a newly created user, so in the same state as "root" would be):
# passwd --unlock --expire test
passwd: Only one of -l, -u, -d, -S may be specified.
Also:
# passwd --unlock test
Unlocking password for user test.
passwd: Warning: unlocked password would be empty.
passwd: Unsafe operation (use -f to force)
The only thing you have to do is "passwd root" to set a password. It's not locked and there's no point in expiring the password to an account you're using yourself...
On Mon, 2022-07-25 at 18:50 -0700, Samuel Sieb wrote:
there's no point in expiring the password to an account you're using yourself...
I see no point in ever expiring any password, unless you're auto- locking out sacked employees because you're too incompetent to do the job properly when they get sacked.
Making people pick new passwords means they're going to write them down so they don't forget them, or keep forgetting them and ask for admin help, or pick stupidly simple ones. If the account has been hacked, changing the password is too late. If it hasn't beeen hacked, there's no point. The next password someone picks might be guessed immediately just by pure chance just as easily as the existing password.
It's just one of those exercises in manifest stupidity and bureaucracy for the sake of it. Oooh, ooh, it's possible for us to make a rule about resetting passwords, so we will.
On 7/26/22 15:52, Tim via users wrote:
On Mon, 2022-07-25 at 18:50 -0700, Samuel Sieb wrote:
there's no point in expiring the password to an account you're using yourself...
I see no point in ever expiring any password, unless you're auto- locking out sacked employees because you're too incompetent to do the job properly when they get sacked.
That situation doesn't make any sense. If it's expired, they can still log in, they just have to change the password first.
You're referring to delayed expiring. The other use case is immediate expiring, which is the case being described here. That's when the admin sets an initial password and tells the user what it is. Then the user has to change the password when they login. Now the admin doesn't know the user's password any more. But again, this doesn't make sense when it's your own password that you're setting.
On Wed, 2022-07-27 at 08:22 +0930, Tim via users wrote:
On Mon, 2022-07-25 at 18:50 -0700, Samuel Sieb wrote:
there's no point in expiring the password to an account you're using yourself...
I see no point in ever expiring any password, unless you're auto- locking out sacked employees because you're too incompetent to do the job properly when they get sacked.
Making people pick new passwords means they're going to write them down so they don't forget them, or keep forgetting them and ask for admin help, or pick stupidly simple ones. If the account has been hacked, changing the password is too late. If it hasn't beeen hacked, there's no point. The next password someone picks might be guessed immediately just by pure chance just as easily as the existing password.
It's just one of those exercises in manifest stupidity and bureaucracy for the sake of it. Oooh, ooh, it's possible for us to make a rule about resetting passwords, so we will.
These "rules" were formulated in the Olden Days, when people had at most one or two logins to mainframes, not dozens or more logins to random websites. They are still enforced mainly by banks, to my eternal frustration. Those same banks won't let me use my password manager to create a genuinely random password and remember it for me.
poc
On Wed, Jul 27, 2022 at 5:22 AM Patrick O'Callaghan pocallaghan@gmail.com wrote:
[...] Those same banks won't let me use my password manager to create a genuinely random password and remember it for me.
Check into one of the KeePass variants.
On Wed, 2022-07-27 at 09:48 -0400, Go Canes wrote:
On Wed, Jul 27, 2022 at 5:22 AM Patrick O'Callaghan pocallaghan@gmail.com wrote:
[...] Those same banks won't let me use my password manager to create a genuinely random password and remember it for me.
Check into one of the KeePass variants.
It has nothing to do with the specific password manager. I'm talking about banks that block the browser from filling in fields on their web page. I have have one that won't even let me use copy-paste.
poc
On Wed, Jul 27, 2022 at 10:05 AM Patrick O'Callaghan pocallaghan@gmail.com wrote:
Check into one of the KeePass variants.
It has nothing to do with the specific password manager. I'm talking about banks that block the browser from filling in fields on their web page. I have have one that won't even let me use copy-paste.
I think KeePass sends keypresses rather than copy-paste, at least when using auto-type of passwords. I *have* encountered sites that inhibit paste, but so far I have not encountered any sites where auto-type doesn't work. Sometimes auto-type has to be customized to accommodate a specific tab sequence, delays for going to a 2nd page, etc.
I still think you should check into it and see if it addresses your issues.
On Wed, 2022-07-27 at 11:04 -0400, Go Canes wrote:
On Wed, Jul 27, 2022 at 10:05 AM Patrick O'Callaghan pocallaghan@gmail.com wrote:
Check into one of the KeePass variants.
It has nothing to do with the specific password manager. I'm talking about banks that block the browser from filling in fields on their web page. I have have one that won't even let me use copy-paste.
I think KeePass sends keypresses rather than copy-paste, at least when using auto-type of passwords. I *have* encountered sites that inhibit paste, but so far I have not encountered any sites where auto-type doesn't work. Sometimes auto-type has to be customized to accommodate a specific tab sequence, delays for going to a 2nd page, etc.
I still think you should check into it and see if it addresses your issues.
I used LastPass (before they changed their policy regarding free accounts) and now used BitWarden. I get round the copy-paste limitation where necessary by using middle-button paste. Since that isn't supported on Windows and MacOS, the designers of these web pages don't have a way to block it. Yet another advantage of using Linux :-)
poc
Tim:
It's just one of those exercises in manifest stupidity and bureaucracy for the sake of it. Oooh, ooh, it's possible for us to make a rule about resetting passwords, so we will.
Patrick O'Callaghan:
These "rules" were formulated in the Olden Days, when people had at most one or two logins to mainframes, not dozens or more logins to random websites. They are still enforced mainly by banks, to my eternal frustration. Those same banks won't let me use my password manager to create a genuinely random password and remember it for me.
I'd rather have a password like: gibbonspaintingunicornsinmybathroom
Than horrendous to type: jil;dfgyu89#$%U#89rdfjkgd
Lots of fun trying to type crap in like that on a mobile phone!
As if any cracker could guess my passphrase any easier than that code! How would it know how many words, just to start with?
Of course you get banks that only let you set an 8-character password, all in the name of security.
Then there's the ones that insist on a number, capital letters, and symbols: StickYour6PasswordRulesUpYours!
Tim:
Of course you get banks that only let you set an 8-character password, all in the name of security.
Joe Zeff:
OK, just use F$ckY0u!
Password already in use, please choose another...
More joking aside, I'll bet that's a very common one.
There's an awful lot of things that want you to login these days, things that really don't need to know who you are. In the past they used to say login using your Hotmail address and password, now it's gmail, and people stupidly do. They give it the password for their email address, instead of setting a password for that service. And then they get owned, either because that site set out to harvest their credentials, or is an easily hacked site that gets them stolen from it.
On Wed, Jul 27, 2022 at 7:37 PM Tim via users users@lists.fedoraproject.org wrote:
Tim:
Of course you get banks that only let you set an 8-character password, all in the name of security.
I've avoided using online bank accounts. When I complain about a withdrawal I didn't make, banks say you must have given your password to someone. I can reply that I don't use online banking and don't have a password to give away. The downside is that I'm sometimes told I don't exist.
There's an awful lot of things that want you to login these days, things that really don't need to know who you are. In the past they usedo say login using your Hotmail address and password, now it's gmail, and people stupidly do. They give it the password for their email address, instead of setting a password for that service. And then they get owned, either because that site set out to harvest their credentials, or is an easily hacked site that gets them stolen from it.
Passwords I used decades ago on vendor sites started appearing on darkweb lists after the vendors either went out of business or were bought by unreliable new owners. I assume passwords make it the dark web when bad actors hack the vendors systems or buy systems at bankruptcy auctions.
There have been some useful studies comparing different password policies. Very long plain text passphrases without time limits are now recommended over shorter passwords that expire every month or two.
I have two-factor authentication enabled wherever it is available, and have been told that real-two factor auth is coming for my bank.
On Wed, 2022-07-27 at 21:11 -0300, George N. White III wrote:
There have been some useful studies comparing different password policies. Very long plain text passphrases without time limits are now recommended over shorter passwords that expire every month or two.
About time!
I have two-factor authentication enabled wherever it is available, and have been told that real-two factor auth is coming for my bank.
What I've seen of some of those TFA, is making it easier for criminals. Steal someone's phone, contact a service and say they need to reset a password, the stolen phone gives them an automatic bypass of security.
On Thu, 2022-07-28 at 12:40 +0930, Tim via users wrote:
On Wed, 2022-07-27 at 21:11 -0300, George N. White III wrote:
There have been some useful studies comparing different password policies. Very long plain text passphrases without time limits are now recommended over shorter passwords that expire every month or two.
About time!
I have two-factor authentication enabled wherever it is available, and have been told that real-two factor auth is coming for my bank.
What I've seen of some of those TFA, is making it easier for criminals. Steal someone's phone, contact a service and say they need to reset a password, the stolen phone gives them an automatic bypass of security.
I have a hardware token for one bank, and a card reader for another.
poc
On 7/27/22 15:37, Tim via users wrote:
Tim:
Of course you get banks that only let you set an 8-character password, all in the name of security.
Joe Zeff:
OK, just use F$ckY0u!
Password already in use, please choose another...
More joking aside, I'll bet that's a very common one.
There's an awful lot of things that want you to login these days, things that really don't need to know who you are. In the past they used to say login using your Hotmail address and password, now it's gmail, and people stupidly do. They give it the password for their email address, instead of setting a password for that service. And then they get owned, either because that site set out to harvest their credentials, or is an easily hacked site that gets them stolen from it.
Most sites that want to use your gmail address will redirect you to google to do the authentication. If not, then don't enter your password. And any site that stores plain-text passwords should be banned from the internet.
On Wed, 2022-07-27 at 18:17 -0700, Samuel Sieb wrote:
Most sites that want to use your gmail address will redirect you to google to do the authentication. If not, then don't enter your password. And any site that stores plain-text passwords should be banned from the internet.
Unfortunately people have little awareness about that. They're also easily fooled by lookalikes.
On Wed, 2022-07-27 at 23:43 +0930, Tim via users wrote:
Tim:
It's just one of those exercises in manifest stupidity and bureaucracy for the sake of it. Oooh, ooh, it's possible for us to make a rule about resetting passwords, so we will.
Patrick O'Callaghan:
These "rules" were formulated in the Olden Days, when people had at most one or two logins to mainframes, not dozens or more logins to random websites. They are still enforced mainly by banks, to my eternal frustration. Those same banks won't let me use my password manager to create a genuinely random password and remember it for me.
I'd rather have a password like: gibbonspaintingunicornsinmybathroom
Than horrendous to type: jil;dfgyu89#$%U#89rdfjkgd
Lots of fun trying to type crap in like that on a mobile phone!
Hence the benefit of a proper password manager, and not having to type anything.
poc
On Fri, 2022-07-22 at 08:12 -0700, stan via users wrote:
On Thu, 21 Jul 2022 12:19:37 -0700 Samuel Sieb samuel@sieb.net wrote:
On 7/21/22 11:18, stan via users wrote:
On Thu, 21 Jul 2022 16:48:57 +0200 Patrick Dupre pdupre@gmx.com wrote:
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
I haven't actually tried this since all my systems so far have had a root account, but sudo useradd -u 1 -p throwawaypassword root should do the trick. Then run sudo passwd --expire root so that root will have to change their password on the first login. Then immediately login as root and set the root password to what you want.
I don't understand how this is an answer to the question. There is always a root account, you can't create one. I think he just wants it to run ".bashrc" at login which it isn't (?) for some reason.
As I said, I haven't actually experienced one of the new setups without root login. passwd --status root If the /root directory is present and root is already assigned to UID 1, then it should only be necessary to remove the lock on the password and set up a password. passwd --unlock --expire root
Root is always UID 0.
poc
On Fri, 22 Jul 2022 23:04:43 +0100 Patrick O'Callaghan pocallaghan@gmail.com wrote:
Root is always UID 0.
Thanks for correcting me. I *know* this, I see it every day when I run ls -n on directories, or top, and yet, my brain somehow went to 1.
On Sat, 23 Jul 2022 18:21:15 -0700 stan upaitag@zoho.com wrote:
On Fri, 22 Jul 2022 23:04:43 +0100 Patrick O'Callaghan pocallaghan@gmail.com wrote:
Root is always UID 0.
Thanks for correcting me. I *know* this, I see it every day when I run ls -n on directories, or top, and yet, my brain somehow went to 1.
Another error. top doesn't show uid, I was thinking of ps. I'll stop now. :-)
On Sat, 2022-07-23 at 18:21 -0700, stan via users wrote:
On Fri, 22 Jul 2022 23:04:43 +0100 Patrick O'Callaghan pocallaghan@gmail.com wrote:
Root is always UID 0.
Thanks for correcting me. I *know* this, I see it every day when I run ls -n on directories, or top, and yet, my brain somehow went to 1.
Been there, done that, got the tee-shirt :-)
poc
On 7/21/22 07:48, Patrick Dupre wrote:
Hello,
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
Thank
Not sure what you are asking. If you want to logon as root, just enter "root" as the user name.
If you want to logon as a regular user and run something automatically as root, put it into your autostart list and wrap it with beesu. You will get a prompt for the root's password before executing.
For example:
beesu -c "/home/linuxutil/lin-bak mount xfs"
On 22/7/22 05:57, ToddAndMargo via users wrote:
On 7/21/22 07:48, Patrick Dupre wrote:
Hello,
How can I have a root account, which execute the bash files (.bashrc ..) at login ?
Thank
Not sure what you are asking. If you want to logon as root, just enter "root" as the user name.
If you want to logon as a regular user and run something automatically as root, put it into your autostart list and wrap it with beesu. You will get a prompt for the root's password before executing.
For example:
beesu -c "/home/linuxutil/lin-bak mount xfs"
From previous experience when I was using Fedora in a VM under windows, and I needed the "root" account, Fedora no longer creates the root account at installation and you have to go through a series of steps to actually create it, which I was given by a person on this list, but unfortunately I don't have those steps anymore having created my system from scratch as a result of hardware upgrades and switching out of raid. It sounds to me like the op is needing that root account but doesn't have it, so getting the steps to create it may resolve his issue?
regards, Steve
users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
On 7/21/22 16:08, Stephen Morris wrote:
From previous experience when I was using Fedora in a VM under windows, and I needed the "root" account, Fedora no longer creates the root account at installation and you have to go through a series of steps to actually create it, which I was given by a person on this list, but unfortunately I don't have those steps anymore having created my system from scratch as a result of hardware upgrades and switching out of raid. It sounds to me like the op is needing that root account but doesn't have it, so getting the steps to create it may resolve his issue?
As I mentioned in an earlier reply, the root account *always* exists. By default, it doesn't have a password, so you can only use "sudo" or an ssh key to login. If you want to be able to login directly as root, you have to set the password.
On 7/21/22 17:08, Stephen Morris wrote:
From previous experience when I was using Fedora in a VM under windows, and I needed the "root" account, Fedora no longer creates the root account at installation and you have to go through a series of steps to actually create it, which I was given by a person on this list, but unfortunately I don't have those steps anymore having created my system from scratch as a result of hardware upgrades and switching out of raid. It sounds to me like the op is needing that root account but doesn't have it, so getting the steps to create it may resolve his issue?
When I installed F35 on this laptop, there was an option in the installer to set up the root account, but it looked like it wasn't active. However, when I clicked on it, I was able to confirm that I did indeed want a root account and then give it a password. I think that the main reason it looks like you can't activate the root account is that most users today don't know how to use root or really need to and they don't want people like that to think that they have to set it up. Much better, I'd think is to have that part of the installation clearly labeled as optional, so that nobody thinks they have to use it, but those of us who do like it don't feel like we have to jump through hoops to get it.