Continuing the discussion from [Question about passwd.pacnew]

root:x:0:0::/root:/bin/bash and root:x:0:0::/root:/usr/bin/bash will work the same because both point at the same file. I changed all users in passwd file to /usr/bin/bash because if ever there’s a problem and the symlink between /bin and /usr/bin breaks, this way it would still work.

  1. No merge.
  2. Delete /etc/passwd.pacnew
  3. (Optional) Edit /etc/passwd to change
root:x:0:0::/root:/bin/bash

to

root:x:0:0::/root:/usr/bin/bash
  1. Done, no headache
2 Likes

Thank you Zesko and Arrababiski, I will try that and reboot.

1 Like

…that’s what merge (and replace) is.

He wrote optional

There is nothing wrong about it.

file /usr/passwd- is backup copy of /usr/passwd

Could then wrote “1. Optional merge” and be done with it. That’s what merge is. That’s what those programs are for. Overwriting conf file and discarding pacnew are just two other options.

Agree, maybe his writing style was not perfect clear… but still it was acceptable and points in the right direction.

All I’m trying to say is that reading Manjaro forum I got a feeling that many people think that dealing with .pacnew files means doing overwrite or discard.

And merging is not optional either, TBH. Let’s say you keep same /bin/bash for users in /etc/passwd but in one year there is new change that removes /bin/bash from /etc/shells since everyone should be using /usr/bin/bash anyway. Unlikely to happen but what will be result? Lot’s of people posting how they’re unable to login for some reason.

This is just an unlikely example. But it definitely happened with other conf files. Things change, stuff gets added and removed. And you have to keep track of that plus make sure your custom config stays in there.

2 Likes

“Ain’t no such thing, old buddy.” (Carl Weathers (R.I.P.), “Predator”, 1987).

It’s /etc/passwd and /etc/passwd-. Yes, having the paths correctly is important. :smile:


As for why the change from /bin/bash to /usr/bin/bash, as has been explained higher up already, /bin is a symbolic link to /usr/bin, and is only there anymore for compatibility reasons, because certain software may still have the /bin and/or /sbin paths hard-coded in when looking for executables, but this is expected to be phased out in the future, and then /bin and /sbin will both be dropped as root-level directory entries.

3 Likes

Thanks, I put /usr/bin/bash in the first line manually and all worked. Thanks for the support.

Also put it further down at the end of the line that my username start with.
Correct?

Yeah I was a bit in a bedazzled maintenance mode when I typed it :stuck_out_tongue:

You can, if you want bash as your default shell, yes.

As long as I can use zsh in Konsole as default, yes.

Yes, you can. You could also add /usr/bin/zsh :person_shrugging:

(Or use the command chsh to not mess up the file with an editor.)

For now, I’d rather not mess with anything related … :slight_smile:

Since I haven’t seen it mentioned yet, I just wanted to put in a plug for vipw if you choose to directly edit /etc/passwd.

sudo vipw

or for those who prefer nano

sudo EDITOR=nano vipw
1 Like

Posting an incorrect path is a simple way to invoke Cunningham’s law
and correct path is shown in @linux-aarhaus quote from 2023

I deleted the pacnew file using the tool:

DIFFPROG=meld pacdiff -s

Glad I came here first to make sure.
This pacnew and pacsave is very confusing at times anda very annoying after big updates…

cool - this will come back at you and bite you
eventually, but : sooner than later :wink:

What do you mean?