SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I use Slackware as my Desktop OS, I have BootSplash and Supermount compiled into the Slackware 10.1's kernel 2.4.29 using the lck1 patch. I'm happy with the kernel's performance.
Slackware 10.1 boot faster but I have been bothered by the delay caused by ldconfig which runs at the system startup.
The ldconfig takes around 5-10 secs to update the library links, after RTFM (reading the fine manual) of ldconfig,
I changed in /etc/rc.d/rc.M file's ldconfig section:
from:
Code:
# Update all the shared library links:
if [ -x /sbin/ldconfig ]; then
echo "Updating shared library links: /sbin/ldconfig"
/sbin/ldconfig
fi
To:
Code:
# Update all the shared library links:
if [ -x /sbin/ldconfig ]; then
echo "Updating shared library links: /sbin/ldconfig"
/sbin/ldconfig -n
fi
I measured the boot time, it was earlier 41 seconds to get to login prompt from lilo screen, and now it is just 35 sec on my Celeron 500 system. I have saved 6 seconds in the Slackware startup. The boot time must be less on faster systems!
my worry is: Is it ok to use ldconfig -n for day to day slackware use?
Could you also tell your startup time upto console login prompt. Thanks.
Here's a solution that Tinkster suggested and that I'm using. It runs ldconfig five minutes after boot, when, presumably, you won't mind it doing its thing in the background:
Quote:
You edit /etc/rc.d/rc.local, append line
/usr/bin/echo "ldconfig" | /usr/bin/at now +5minutes
That will run ldconfig 5 minutes after the boot-scripts
have finished, X and your "most important apps"
should be up & running, and the process in the
background shouldn't bother you too much
I know this is off topic and I apologise if this upsets anyone, but it is not ldconfig that annoys me at start-up.
It is the disk checking, I have 10 partitions over 2 disks, mainly formatted with reiserfs. At boot each partition is checked. Many moons ago, when I used debian, each partition was checked after a different number of boots. Therefore no more than two but usually only one partition was checked at each boot-up.
If I could do this with slackware it would save perhaps 30-60 seconds of boot time.
that's weird... i use reiserfs and even after an unclean reboot the check takes less than two seconds (after a clean reboot it takes less than ONE second)... it's one of the many reasons i moved from ext3 to reiserfs...
Probably different transfer rates, which would be dictated by the speed of the ide-bus, but the majority of my boot time is taken by 10 partition checks.
Any idea what file controls this part of the boot procedure.
Originally posted by samac I know this is off topic and I apologise if this upsets anyone, but it is not ldconfig that annoys me at start-up.
It is the disk checking, I have 10 partitions over 2 disks, mainly formatted with reiserfs. At boot each partition is checked. Many moons ago, when I used debian, each partition was checked after a different number of boots. Therefore no more than two but usually only one partition was checked at each boot-up.
If I could do this with slackware it would save perhaps 30-60 seconds of boot time.
Any ideas?
samac
You don't want to do anything like that with a journaled FS. ReiserFS needs a quick check on every boot to see if it was in the middle of something...if it was, you *DO NOT* want it to continue...if it wasn't, it's fine, and very quick.
Originally posted by dhave Here's a solution that Tinkster suggested and that I'm using. It runs ldconfig five minutes after boot, when, presumably, you won't mind it doing its thing in the background:
Quick questions why wouldn't ldconfig run when I do echo "ldconfig"? I know it's not running because it only echoes 'ldconfig' to standard output and nothing happens, but when I run 'ldconfig' in the shell it works. I know it works when I just run 'ldconfig' without the echo because there is HD activity. When I do it with the 'echo "ldconfig"' nothing happens except the 'echo' function.
Is there a relation with "/usr/bin/at now +5minutes" that helps execute the actual 'ldconfig' binary?
the echo command will simply print the given string (may be formated or not).
When you execute: /usr/bin/echo "ldconfig" | /usr/bin/at now +5minutes
"echo" is actually telling to "at" that ldconfig is like a string entered from keyboard, which is what at needs.
The "at" command accepts a time as parameter (in this case +5minutes) and then it asks you for a command, by passing "ldconfig" string in the pipe, you're actually making "at" to think that "ldconfig" string was entered by the user.
That's the funciton of the | character, to tell a program to read the output of a program executed before as input for it.
If you use "ldconfig | /usr/bin/at now +5minutes" it won't work, because you're executing "ldconfig" program and passing it's output (it doesn't have) to "at".
But when you use "echo "ldconfig" | /usr/bin/at now +5minutes" you're executing the "echo" command which will output just "ldconfig" (a string) and pass that to "at".
Originally posted by gbonvehi the echo command will simply print the given string (may be formated or not).
When you execute: /usr/bin/echo "ldconfig" | /usr/bin/at now +5minutes
"echo" is actually telling to "at" that ldconfig is like a string entered from keyboard, which is what at needs.
The "at" command accepts a time as parameter (in this case +5minutes) and then it asks you for a command, by passing "ldconfig" string in the pipe, you're actually making "at" to think that "ldconfig" string was entered by the user.
That's the funciton of the | character, to tell a program to read the output of a program executed before as input for it.
If you use "ldconfig | /usr/bin/at now +5minutes" it won't work, because you're executing "ldconfig" program and passing it's output (it doesn't have) to "at".
But when you use "echo "ldconfig" | /usr/bin/at now +5minutes" you're executing the "echo" command which will output just "ldconfig" (a string) and pass that to "at".
Wow wasn't expecting an elaborate explanation. Thanks
- turning off hotplug
- commenting out /sbin/ldconfig in /etc/rc.d/rc.M
- commenting out /usr/X11R6/bin/fc-cache in /etc/rc.d/rc.M
With the exception of hotplug (which some may find useful), I really don't understand why PV thinks these things are necessary during boot up. (They should be done during normal operation as required.) I would also comment out "/sbin/depmod -a" in rc.modules for being of dubious necessity, but it doesn't take long enough for me to care about it.
Originally posted by Nobber I improved my boot-up time (considerably) by
- turning off hotplug
- commenting out /sbin/ldconfig in /etc/rc.d/rc.M
- commenting out /usr/X11R6/bin/fc-cache in /etc/rc.d/rc.M
With the exception of hotplug (which some may find useful), I really don't understand why PV thinks these things are necessary during boot up. (They should be done during normal operation as required.) I would also comment out "/sbin/depmod -a" in rc.modules for being of dubious necessity, but it doesn't take long enough for me to care about it.
I have done exactly as Nobber has. ldconfig, fc-cache, etc. these things are not necessary to run every boot. You only need to run ldconfig when you compile and install programs yourself afaik, or in the case of a major upgrade, fc-cache only when you add / remove fonts manually.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.