Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Help with: /proc/kmsg -> "No such file or directory"
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
youngka
n00b
n00b


Joined: 04 Sep 2005
Posts: 50

PostPosted: Thu Mar 16, 2006 9:51 pm    Post subject: Help with: /proc/kmsg -> "No such file or directory& Reply with quote

Hi all,

Code:

myTerm ~ # /etc/init.d/syslog-ng start                                    [ ok ]
 * Starting syslog-ng ...
Error opening file /proc/kmsg for reading (No such file or directory)
Error initializing configuration, exiting.
 * Failed to start syslog-ng                                            [ !! ]
myTerm ~ #


I have a VPS server running Gentoo, and after a reboot I noticed that syslog-ng wasn't running. It shows the above error when I try to start it. I have been Googling like mad to try and figure out where the heck kmsg comes from and how to get it back, but I am at a loss. Can someone please help me with instructions on how to get /proc/kmsg to show up again? I have taken out the kernel logging for now in syslog-ng.conf to get at least some logging happening, but I (obviously) would like to get kernel logging restored.

The VPS account is an "unmanaged" account, so the host isn't very helpful with this.

Cheers,
Keith.
Back to top
View user's profile Send private message
widan
Veteran
Veteran


Joined: 07 Jun 2005
Posts: 1512
Location: Paris, France

PostPosted: Thu Mar 16, 2006 10:07 pm    Post subject: Re: Help with: /proc/kmsg -> "No such file or direct Reply with quote

youngka wrote:
I have a VPS server running Gentoo, and after a reboot I noticed that syslog-ng wasn't running.

Did it work properly before ?
youngka wrote:
figure out where the heck kmsg comes from

It comes from the kernel (through the proc filesystem). If you read that file, you get the kernel log messages (that are written by printk inside the kernel).
youngka wrote:
how to get it back

It should always be there, the kernel creates it... Check that /proc is mounted, just in case (but the boot process would have complained about it). Look at what you have in /proc, does it look normal, or is it empty ?
Back to top
View user's profile Send private message
ryker
Guru
Guru


Joined: 28 May 2003
Posts: 412
Location: Portage, IN

PostPosted: Tue Jun 13, 2006 12:02 pm    Post subject: Reply with quote

Did you ever find a solution to this? I am having the same problem. I am using Gentoo Vserver and I just updated one of the hosts, ran dispatch-conf, and rebooted the guest. Now I'm getting the same kmsg error. I checked /proc and it is there. I also recompiled syslog-ng, and I get the same error.
_________________
Athlon 64 3200+, 80G WD sata hd + 200G IDE, 1G Geil DDR400, MSI K8T Neo
IntelCore2Duo 2.0Ghz MSI laptop,100G SATA hd, 2G RAM
Back to top
View user's profile Send private message
ryker
Guru
Guru


Joined: 28 May 2003
Posts: 412
Location: Portage, IN

PostPosted: Sat Jun 17, 2006 3:28 pm    Post subject: Reply with quote

I guess not. I switched to metalog, and everything seems ok now. I never could get syslog-ng to work again.
_________________
Athlon 64 3200+, 80G WD sata hd + 200G IDE, 1G Geil DDR400, MSI K8T Neo
IntelCore2Duo 2.0Ghz MSI laptop,100G SATA hd, 2G RAM
Back to top
View user's profile Send private message
xbot
n00b
n00b


Joined: 23 Aug 2005
Posts: 7
Location: Germany

PostPosted: Fri Jul 07, 2006 9:17 am    Post subject: Reply with quote

Got it solved!

I have gentoo running on a 1and1 Vserver too . (orig System SuSe 9.3)

Have copied the syslog-ng file from a SuSe 10 server.
Now syslog is working again!

Just change the following lines:

Code:

options { long_hostnames(off); sync(0); perm(0640); stats(3600); };

source src { internal(); unix-dgram("/dev/log"); };
Back to top
View user's profile Send private message
dev-urandom
Apprentice
Apprentice


Joined: 24 Jun 2005
Posts: 260
Location: Huh?

PostPosted: Fri Jul 07, 2006 10:53 am    Post subject: Reply with quote

Are you guys running selinux? I've seen similiar errors on some redhat systems when I upgraded. If you really don't have /proc/kmesg, well then thats a really funky kernel configuration that you folks have ;)
_________________
/earth: file system full.
Back to top
View user's profile Send private message
ryker
Guru
Guru


Joined: 28 May 2003
Posts: 412
Location: Portage, IN

PostPosted: Fri Jul 07, 2006 1:30 pm    Post subject: Reply with quote

Thanks xbot, I'll give that a try when I get a chance. I've changed most of my machines over to metalog since syslog-ng died.

@dev-urandom: /proc/kmsg exists, syslog just says it doesn't.
_________________
Athlon 64 3200+, 80G WD sata hd + 200G IDE, 1G Geil DDR400, MSI K8T Neo
IntelCore2Duo 2.0Ghz MSI laptop,100G SATA hd, 2G RAM
Back to top
View user's profile Send private message
dev-urandom
Apprentice
Apprentice


Joined: 24 Jun 2005
Posts: 260
Location: Huh?

PostPosted: Sat Jul 08, 2006 12:46 pm    Post subject: Reply with quote

ryker wrote:
@dev-urandom: /proc/kmsg exists, syslog just says it doesn't.


Hmm, do you have selinux enabled? Also, please post the last few lines of /var/log/messages when you restart syslog-ng.
_________________
/earth: file system full.
Back to top
View user's profile Send private message
ryker
Guru
Guru


Joined: 28 May 2003
Posts: 412
Location: Portage, IN

PostPosted: Tue Jul 25, 2006 4:49 pm    Post subject: Reply with quote

Sorry it took so long for me to reply. As I mentioned in my last post, I have switched all of my servers to metalog to quickly fix the problem. I just installed a new server (new to me) and I am running into the same problem after I did an emerge -uD world on a fresh install. It looks like syslog-ng is the same version as before I updated world. I'm not in too much of a rush for this server, so I can spend some time trying to figure out what's wrong.
Here is some more information about the problem.

When I try to start syslog-ng, I get the following:
Code:

 * Starting syslog-ng ...
Error opening file /proc/kmsg for reading (Operation not permitted)
Error initializing configuration, exiting.
 * Failed to start syslog-ng


/var/log/messages only shows syslog-ng going down for reboot after I upgraded. No new log entries. Here is a tail of /var/log/messages:
Code:
Jul 24 23:54:48 jackassvs1 init: Trying to re-exec init
Jul 24 23:54:48 jackassvs1 init: no more processes left in this runlevel
Jul 25 04:37:50 jackassvs1 syslog-ng[11715]: STATS: dropped 0
Jul 25 05:46:39 jackassvs1 rc-scripts: gcc-config: No gcc profile is active!
Jul 25 05:46:44 jackassvs1 rc-scripts: If you intend to use the gcc from the new profile in an already
Jul 25 05:46:44 jackassvs1 rc-scripts: running shell, please remember to do:
Jul 25 05:46:44 jackassvs1 rc-scripts:   # source /etc/profile
Jul 25 11:31:27 jackassvs1 shutdown[6870]: shutting down for system reboot
Jul 25 11:31:27 jackassvs1 init: Switching to runlevel: 6
Jul 25 11:31:31 jackassvs1 syslog-ng[11715]: syslog-ng version 1.6.9 going down


I am currently using syslog-ng 1.6.9

ls -lah /proc/kmsg shows:
Code:
-r-------- 1 root root 0 Jul 22 00:43 /proc/kmsg

Seems strange that it has 400 permission. Shouldn't it at least have 444?

Please letm me know if you need any further info.

Thanks for your help.
_________________
Athlon 64 3200+, 80G WD sata hd + 200G IDE, 1G Geil DDR400, MSI K8T Neo
IntelCore2Duo 2.0Ghz MSI laptop,100G SATA hd, 2G RAM
Back to top
View user's profile Send private message
G104cch1n0
n00b
n00b


Joined: 22 May 2010
Posts: 4

PostPosted: Sun Mar 17, 2013 2:39 pm    Post subject: Reply with quote

Still experiencing this problem :|

Someone found a fix ?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum