/var/log/messages permission denied


(Jahid) #1

Hey everyone,

I’m trying to check my error messages in the terminal app on the Putty. This is the output that I’ve had so far:

[~]# /var/log/messages
-bash: /var/log/messages: Permission denied

Do you guys happen to know why it won’t let me use the sudo commands?

Thanks all!

(Sayem Hossain) #2

Have you tried this?
sudo cat /var/log/messages
Looks like your user doesn’t have permission to open that file. Aparantly you need to login as a root user to access /var/* folders.
Alternately you can modify file permission
sudo su && sudo chmod 755 -R /var/log/messages


(NH Shiplu) #3

Try This…
[~]# /vi /log/messages