sudo su error

Commissario
Joined
16 Oct 2002
Posts
343,188
Location
In the radio shack
Every time I sudo su on a CentOS7 system, I get this error.

Code:
bash: /root/.cache/abrt/lastnotification.Fl580G5f: cannot overwrite existing file
'abrt-cli status' timed out

The number after lastnotification is different every time.

There is a file in /root/.cache/abrt called lastnotification.

I've tried giving it +777 permissions, I get the same error.

I've even deleted it, it makes no difference. It comes back with these permissions.

Code:
-rw-------  1 root root 0 Aug 14 23:27 lastnotification

It's just a little frustrating, anyone know what I can do to fix this?

Thanks.
 
It's not just the
'abrt-cli status' timed out
message, it's the previous line that's bugging me as well.

Creating a .hushlogin in /root doesn't make any difference :(

Red Hat support subscription, maybe the solution for this will help (I can't see it as I don't have said subscription) - https://access.redhat.com/solutions/3077311
Thanks, that would be really useful is someone is able to look at that for me.
 
I've been able to find that info and basically it's saying to make sure the owner of /root/.cache/abrt/lastnotification is set to root.

Already checked that - It's set correctly.
 
There's something odd.

https://tuxrootsite.wordpress.com/2019/04/18/disable-last-login-message-centos-7/

When I run
>/var/log/lastlog

I get an error...

bash: /var/log/lastlog: cannot overwrite existing file


Which is strangely similar to the error I'm getting when sudo su

bash: /root/.cache/abrt/lastnotification.Fl580G5f: cannot overwrite existing file

I am root - I've logged in and done a sudo su so I should be able to overwrite these files.
 
Looking back over the thread, you get the error with "sudo su", but not with "sudo su -"? If so, it might be something to do with the environment of your normal user.

It's really inconsistent.

Sometimes I get the single error, sometimes I get both errors, sometimes I get a 'last time I logged on' message, sometimes I don't.

No matter what I try, including the +noclobber from my own login, it literally is different each time I issue the same sudo su or sudo su - command.

However...

sudo -i

Just drops me to a # prompt. No last login message, no error.
 
Back
Top Bottom