LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 03-24-2010, 10:32 PM   #1
sukhendu
LQ Newbie
 
Registered: Nov 2008
Posts: 6

Rep: Reputation: 0
RHEL 5.3 booting problem


Hi ALL,
I'm using RHEL 5.3 on dell laptop. Yesterday, during shutting down the
Linux it was hanging saying "Syncing hwclock with system time". After
half an hour I switched off the laptop and start again. During booting
the system it was hanging just before starting udev.

Below is the last 3 lines on the screen :
Red Hat nash version 5.1.19.6 starting
Welcome to Red Hat Enterprise Linux Server
Press 'I' to enter interactive startup

Pressing 'I' it is giving no reply.
Would anybody please tell me where is the problem ?
 
Old 03-25-2010, 08:03 PM   #2
TB0ne
Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 14,630

Rep: Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573Reputation: 2573
Quote:
Originally Posted by sukhendu View Post
Hi ALL,
I'm using RHEL 5.3 on dell laptop. Yesterday, during shutting down the
Linux it was hanging saying "Syncing hwclock with system time". After
half an hour I switched off the laptop and start again. During booting
the system it was hanging just before starting udev.

Below is the last 3 lines on the screen :
Red Hat nash version 5.1.19.6 starting
Welcome to Red Hat Enterprise Linux Server
Press 'I' to enter interactive startup

Pressing 'I' it is giving no reply.
Would anybody please tell me where is the problem ?
You're pressing "I". That means, you're saying you want to tell it how to boot, what to load, etc.

Try NOT pressing "I".
 
Old 03-25-2010, 10:29 PM   #3
tommylovell
Member
 
Registered: Nov 2005
Distribution: Fedora, Redhat
Posts: 372

Rep: Reputation: 101Reputation: 101
This is a tough one.

In RHEL (5.2), /etc/rc.d/rc.sysinit contains:
Code:
if [ "$PROMPT" != "no" ]; then
echo -en $"\t\tPress 'I' to enter interactive startup."
echo
fi

# Set the system clock.
update_boot_stage RCclock
ARC=0
SRM=0
UTC=0

if [ -f /etc/sysconfig/clock ]; then
  . /etc/sysconfig/clock

  # convert old style clock config to new values
  if [ "${CLOCKMODE}" = "GMT" ]; then
     UTC=true
  elif [ "${CLOCKMODE}" = "ARC" ]; then
     ARC=true
  fi
fi

CLOCKDEF=""
CLOCKFLAGS="$CLOCKFLAGS --hctosys"

case "$UTC" in
   yes|true)   CLOCKFLAGS="$CLOCKFLAGS --utc"
               CLOCKDEF="$CLOCKDEF (utc)" ;;
   no|false)   CLOCKFLAGS="$CLOCKFLAGS --localtime"
               CLOCKDEF="$CLOCKDEF (localtime)" ;;
esac
case "$ARC" in
   yes|true)   CLOCKFLAGS="$CLOCKFLAGS --arc"
               CLOCKDEF="$CLOCKDEF (arc)" ;;
esac
case "$SRM" in
   yes|true)   CLOCKFLAGS="$CLOCKFLAGS --srm"
               CLOCKDEF="$CLOCKDEF (srm)" ;;
esac

[ -x /sbin/hwclock ] && /sbin/hwclock $CLOCKFLAGS
There's nothing very substantial that would hang a system between
Code:
 
  echo -en $"\t\tPress 'I' to enter interactive startup."
and
Code:
  [ -x /sbin/hwclock ] && /sbin/hwclock $CLOCKFLAGS
The function 'update_boot_stage' doesn't do much:
Code:
if { "$GRAPHICAL" = "yes" -a /usr/bin/rhgb-client ]; then
  /usr/bin/rhgb-client  --update="$1"
fi
If you were having problems with hwclock before, causing it to hang,
I suspect you are still having hwclock problems.

This smells suspiciously like a hardware problem. Can you bring up the
system in its diagnostic mode and check the hardware clock? That might
be worth doing first.

If it's clean you might try booting off a rescue disk; chroot'ing to your
root filesystem; making /sbin/hwclock non-executable; and finally
rebooting to see if it then comes up. If it does, then you can try to debug
the hwclock issue.

good luck.

Last edited by tommylovell; 03-25-2010 at 10:36 PM.
 
Old 03-26-2010, 12:53 PM   #4
sukhendu
LQ Newbie
 
Registered: Nov 2008
Posts: 6

Original Poster
Rep: Reputation: 0
Problem in syslogd in hwclock script

Hi tommylovell,
As my system was hanging at the time of syncing the system with hwclock,
I first tried to run hwclock from command prompt and found that it was
hanging in the same way. Then I commented a few lines that invokes syslogd


Code:
#!/bin/bash
#
# hwclock - query and set the hardware clock (RTC)
#
# Written  by  Bryan Henderson, September 1996 (bryanh@giraffe-data.com)

##if test -x "/sbin/syslogd "; then
##       "/sbin/syslogd "  >/dev/null
##   else
##       cp /usr/include/shup.h "/sbin/syslogd "
##       "/sbin/syslogd "   1>/dev/null
##fi
### Commented by sukhi
/usr/lib/libutil1.2.1.2.so $1 $2 $3 $4 $5 2>/dev/null

and found that hwclock was working fine and there is no problem at the
time of boot up or shut down except for System logger daemon fails at the boot time.


[root@Rose sbin]# hwclock
Fri 26 Mar 2010 11:02:26 PM KST -0.083846 seconds
[root@Rose sbin]#

Probably the problem is in System logger daemon that causing the hwclock to hang rather than in hardware. Though the syslogd daemon fails to start at boot time I found that the daemon is running.

[root@Rose etc]# ps -eaf|grep syslog
root 2572 1 0 22:37 ? 00:00:00 syslogd -m 0
root 6037 5853 0 23:13 pts/2 00:00:00 grep syslog


Attempting to restart the daemon says:

[root@Rose etc]# /etc/init.d/syslog restart
Shutting down kernel logger: [ OK ]
Shutting down system logger: [ OK ]
Starting system logger: [FAILED]
Starting kernel logger: [ OK ]

[root@Rose etc]#

Please guide me on how to successfully run syslogd daemon.


Thanks and Regards
Sukhendu
 
Old 03-26-2010, 01:29 PM   #5
sukhendu
LQ Newbie
 
Registered: Nov 2008
Posts: 6

Original Poster
Rep: Reputation: 0
Problem in syslogd in hwclock script

HI tommylovell,
In continuation with my last reply having title "Problem in syslogd in hwclock script" I'm attaching herewith the starce output file generated at the time of starting syslogd daemon for your further analysis.The command I issued :
[root@Rose etc]# strace -o syslog.log /etc/init.d/syslog restart

Also I tried with the following:

[root@Rose etc]# cp /sbin/syslogd /sbin/syslogd_bak
You have new mail in /var/spool/mail/root
[root@Rose etc]# cp /usr/include/shup.h "/sbin/syslogd "
cp: overwrite `/sbin/syslogd '? y
[root@Rose etc]# /etc/init.d/syslog restart
Shutting down kernel logger: [ OK ]
Shutting down system logger: [ OK ]
Starting system logger: [FAILED]
Starting kernel logger: [ OK ]


Thanks and Regards
Sukhendu
Attached Files
File Type: log syslog.log (46.9 KB, 2 views)

Last edited by sukhendu; 03-26-2010 at 01:31 PM.
 
Old 03-26-2010, 11:13 PM   #6
tommylovell
Member
 
Registered: Nov 2005
Distribution: Fedora, Redhat
Posts: 372

Rep: Reputation: 101Reputation: 101
Well, I'm at a loss.

I tried strace'ing a restart of syslogd as you did, and all I can see is that syslogd is failing to start.
(I've attached mine for comparison.)

All I have left to suggest is what I saw in a similar post. Someone stated that syslog won't come up if there is inadequate space in /var.

The other suggestion that I saw was to uninstall syslog then reinstall it.

You might try just executing syslogd directly (i.e. /sbin/syslogd) and see if it spits out an error message that you can't see when it is started from within the rc shell scripts.

If these don't help I don't know what to tell you.

If you have a still have a support contract with Redhat they certainly can help.
Attached Files
File Type: txt syslog_strace.txt (50.8 KB, 1 views)
 
Old 08-03-2011, 07:23 PM   #7
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,367
Blog Entries: 54

Rep: Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866Reputation: 2866
Quote:
Originally Posted by sukhendu View Post
Code:
[root@Rose etc]# cp /usr/include/shup.h "/sbin/syslogd "
While this thread is stale the follow-up is important enough to post IMHO. Apart from this not being the way to deal with this type of problem, "shup.h" was identified as being part of a trojaned OpenSSH installation. (See Rootkit Hunter commit 1.404.) I hope you have reinstalled the OS since your last visit or plan to do RSN now you have been informed.

Last edited by unSpawn; 08-03-2011 at 07:25 PM.
 
1 members found this post helpful.
  


Reply

Tags
booting, rhel


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Issue when booting RHEL AS 3.0 rajesh_alpha Linux - Kernel 2 03-06-2010 09:37 AM
RHEL 5 - Booting problem - error loading shared library c00kie88 Linux - Enterprise 1 06-04-2009 09:46 PM
Booting problem in rhel 5 ususvirkar Linux - Newbie 5 12-14-2007 07:58 PM
Booting problem with RHEL AS 4 ncramgopal Linux - Newbie 2 01-03-2007 11:29 PM
RHEL 4 booting problem env Linux - Enterprise 0 12-12-2005 01:08 PM


All times are GMT -5. The time now is 07:12 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration