LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Why Slackware runs fast? (https://www.linuxquestions.org/questions/slackware-14/why-slackware-runs-fast-657778/)

nuxrl 07-23-2008 04:00 PM

Why Slackware runs fast?
 
We've heard a lot that Slackware runs faster than most other Linux distros. My personal experience (not benchmarked) also backs this statement. Slackware and Slackware-based distros (Vector, Wolvix, Zenwalk, ...) usually run very fast. I am trying to understand the reason. Slackware doesn't tweak the kernel. It doesn't use aggressive optimization options to build its packages. I know it uses BSD style startup scripts and doesn't turn on too many services in /etc/rc.d by default. This may speed up the system boot process but doesn't make programs run faster in the system. The file directory structure in Slack is not significantly different from other distros'.

If Slack really runs faster than others, what are the reasons?

Takla 07-23-2008 04:27 PM

It has a special hidden directory where all the magic happens

/.placebo

:p

jong357 07-23-2008 04:47 PM

Personally, I believe it to be from minimal source code patching. Go look at Fedora Rawhide and you'll shutter. upwards to 20 patches on some packages. BTW, Debian does it too. ;)

I have nothing to back that assumption up, but am not sure what else to attribute it to. My DIY build runs just as fast. Something to be said for Vanilla Linux I think.

the3dfxdude 07-23-2008 07:56 PM

Maybe because it gets in your way less.

gnashley 07-24-2008 02:31 AM

"doesn't turn on too many services" is the main reason, I believe.

owenjh 07-24-2008 07:21 AM

Slackware does run faster than many distributions on a base install. I have tweaked a Slackware system to boot on old hardware in 30 seconds.

Slackware does not have as many services turned on by default which is one reason. You also do not get a lot of packages (unless you select the full) option that you don't need. I'm not sure the effect of this on boot time but it can definitely slow your computer down at runtime.

Getting benchmarks of different OS's was on my list of stuff todo, just haven't got around to doing it yet.

monsm 07-24-2008 07:58 AM

Pure and utter magic, I'd say. Almost as good as Gentoo ;)

Mons

GazL 07-24-2008 08:35 AM

Not using SELinux, GRSecurity or AppArmor probably doesn't hurt much either. All those additional authorisation checks don't come for free, though for the most part I doubt the lost clock cycles would be noticeable to a human.

My primary system (4 year old, Pentium 4 3.0Ghz Hyperthreading) just died on me. I'm typing this on an old Dell XPS B Series, P3-800 which I've resurrected to tide me over. I get the feeling it will continue to run forever if I let it. <OLD FART MODE>"They don't build 'em like this anymore, sonny!". It has 128mb of ram and a 32Mb GeForce 256 card. I'm running slack 12.1 (X but no KDE) and even on an encrypted LVM setup its surprisingly usable for a machine of its vintage. Memory is a bit on the tight side, but otherwise it makes me wonder if its actually worth replacing my P4 at all. It runs a damn sight cooler than my P4 too.


To be honest though, I can't say I've ever noticed a speed difference between Slackware and any of the other distros I've tried: though I've never been a fan of the full-fat desktop environments such as KDE and GNOME, which may go some way to explaining that.

granth 07-24-2008 09:32 AM

I have an old HP Vectra workstation: P3 733mhz, 512mb RAMBUS (lol).

Any recent Fedora release is absolutely unbearable to use. However, Slackware seems to run ok, even using KDE. I would even say that it "seems" faster than my brother's P4 with Ubuntu installed.

simple = fast

GazL 07-24-2008 10:51 AM

My P800 is RAMBUS too Granth. Unfortunately only 128MB (though back in those days, that was a lot of RAM... hehe) and getting any extra for it these days is probably not a viable option.

I was just casting a tentative eye over the Dell Precision Workstation range. XPSes have gotten a little too tricked-up for my liking these days. All those colour changing LED light strips and what have you on the front may make the kids go 'Woah!... Cooooooool", but they don't do anything for me.

alisonken1 07-24-2008 06:28 PM

Slackware doesn't try to coddle you or save you from yourself.

Eye candy (unless using accelerated hardware) wastes cycles better spent on doing work.

Protecting you from yourself means limiting options and wasting cycles on stuff that should not be needed for someone trying to learn, or for serious admins, gets in your way.

By keeping it simple, it's easier to setup and easier to maintain. Since you don't have extra cruft getting in the way, a byproduct is also extra cycles for getting work done as well as an excellent working example that lets you play (even if it means getting yourself in trouble, like 'rm -rf /').

Franklin 07-24-2008 06:46 PM

Honestly, I blame Gnome and all the added crap a typical Gnome install adds. Dumping it was the best thing Pat ever did. I've installed GSB and while that still runs faster than Gnome on other distros, it added way too many useless (IMO) daemons and services. Pare it down to an acceptable level and it fails to run correctly. It runs sluggish under X as well.

When you consider that Gnome is the default DE for Ubuntu, Debian, and Suse (I think), and is installed on many more Distros (even if it isn't the default DE) then maybe there's a connection?

Eh, what do I know ...

;)

jong357 07-25-2008 11:30 AM

So your saying that Slackware didn't become fast until gnome-2.6 was dropped?

hitest 07-25-2008 11:46 AM

Slackware doesn't load a lot of extra services on boot-up, less system overhead, so it runs quite fast:-) Slackware is a lean, durable, secure OS.
Slackware 12.1 with XFce 4.4.2 runs smooth as silk on my main work station, an IBM Celeron 850 MHz, with 768 MB RAM. Slackware 12.1 also runs very well indeed on my IBM Plll 667 Mhz, with 256 MB RAM.

Takla 07-25-2008 12:29 PM

I think it's just about what services are enabled, there's no magic to it. Recently I tried Arch and of course it seems very fast at first because it's minimal. Once you add the same services and use the same applications as in another distro there's no appreciable difference. There are distros like the Suse ones which use their own tools, services and structure and might not be capable of performing as well but I'd guess any distro that is based on traditional commonly used tools can be made to perform pretty much the same. It's really a question of building on a minimal base vs removing from a more comprehensive default set-up.

I listened to a podcast recently where the authors, a Debian user and a Gentoo user, tested Ubuntu Hardy. They found no appreciable difference in performance between Ubuntu and Gentoo using geekbench testing tools except Ubuntu has a bigger RAM footprint, which might be explained by the use of prelinking/readahead. I've recently tested for my own interest Debian Lenny, Arch, Ubuntu Hardy, gNewSense and once they're configured with the same kernel, services and desktop environments (as far as is possible) I found the same thing. The only real variables seem to be boot time and memory footprint which I'm inclined to think is the result of different start up scripts and prelinking.

BCarey 07-25-2008 02:49 PM

Quote:

Originally Posted by Franklin (Post 3225498)
Honestly, I blame Gnome and all the added crap a typical Gnome install adds. Dumping it was the best thing Pat ever did. I've installed GSB and while that still runs faster than Gnome on other distros, it added way too many useless (IMO) daemons and services. Pare it down to an acceptable level and it fails to run correctly. It runs sluggish under X as well.

When you consider that Gnome is the default DE for Ubuntu, Debian, and Suse (I think), and is installed on many more Distros (even if it isn't the default DE) then maybe there's a connection?

Eh, what do I know ...

;)

I go back and forth between gnome and kde and I don't notice any speed difference.

Brian

arfon 07-25-2008 02:57 PM

Gnome? KDE?? XFCE??? You big babies! I run TWM and I likes it!

:)

Franklin 07-25-2008 05:47 PM

Quote:

Originally Posted by jong357 (Post 3226194)
So your saying that Slackware didn't become fast until gnome-2.6 was dropped?

No - though it does sort of sound like that.

The original question - as I interpreted it - was why is Slackware faster than other distros? My statement was that I believe that in many circumstances Gnome adds services that seem to put a drag on the system - subjective statement all the way.

What I did not add was that Slackware's Gnome - when Pat included it - was not what most peopled considered a full Gnome desktop. Some even considered it broken. Regardless, I think it's safe to say that the Gnome that Pat did include was not so bloated that it dragged the system down to the point you would notice the difference when it was gone.

Other distros do include a more complete Gnome so, if you subscribe to my unsubstantiated theory, this would make other distros appear sluggish in comparison to Slackware.

Alexvader 10-21-2009 10:49 AM

Quote:

Originally Posted by owenjh (Post 3224859)
Slackware does run faster than many distributions on a base install. I have tweaked a Slackware system to boot on old hardware in 30 seconds.

Slackware does not have as many services turned on by default which is one reason. You also do not get a lot of packages (unless you select the full) option that you don't need. I'm not sure the effect of this on boot time but it can definitely slow your computer down at runtime.

Getting benchmarks of different OS's was on my list of stuff todo, just haven't got around to doing it yet.

Hi Ownjh

May I ask what have you done...?

Did you recompile a kernel, besides of disabling stuff in the runlevels...

Seems to me that the .huge kernel just takes too long to load...

I boots real fast though, could it boot faster... ? :-)

BRGDS

Alex

vinegaroon 10-21-2009 07:15 PM

Quote:

Originally Posted by Alexvader (Post 3727371)
Hi Ownjh

May I ask what have you done...?

Did you recompile a kernel, besides of disabling stuff in the runlevels...

Seems to me that the .huge kernel just takes too long to load...

I boots real fast though, could it boot faster... ? :-)

BRGDS

Alex

My netbook (Dell Mini 9) boots Slackware 13.0 from the bootloader to login in ~8 seconds. It is quite doable.
Things to try:
- compile a new kernel
- disable unneeded rc scripts
- edit other rc scripts to your needs (mostly rc.M, rc.S)

slackd 10-21-2009 09:33 PM

Quote:

Originally Posted by Alexvader (Post 3727371)
Hi Ownjh

May I ask what have you done...?

Did you recompile a kernel, besides of disabling stuff in the runlevels...

Seems to me that the .huge kernel just takes too long to load...

I boots real fast though, could it boot faster... ? :-)

BRGDS

Alex

Things u can do:

1. Compile the new dev kernel 2.6.32-rc5, it gives me a performance boost over the 2.6.31.4 i had. (remember ur looking for total customization according to ur specific needs, tweaking will take some and is not a one step process, take ur time).
2. Edit & customize rc scripts (rc.M/S) as told above.

ibwew 10-21-2009 10:15 PM

Well...I don't have any facts to prove my theory....but I think Pat has been consulting with Doc and Marty and they have really improved the Flux Capacitor!! It wouldn't surprise me to see the Delorean taking off at 60 mph instead of 88 mph soon. I'm sure they have been working hard tweaking everything so we can all go BACK TO THE FUTURE!!

alexiy 10-22-2009 06:27 AM

Quote:

Originally Posted by owenjh (Post 3224859)
Slackware does run faster than many distributions on a base install. I have tweaked a Slackware system to boot on old hardware in 30 seconds.

Slackware does not have as many services turned on by default which is one reason. You also do not get a lot of packages (unless you select the full) option that you don't need. I'm not sure the effect of this on boot time but it can definitely slow your computer down at runtime.

Getting benchmarks of different OS's was on my list of stuff todo, just haven't got around to doing it yet.

Hi,

Are you going to create a topic with a description how you did your optimization to achieve 30 sec?

Since I'm using external drive to run my Slacka I can't use hibernation. So this topic is quite touchy for me :)

Thank you... That will be really interesting to see Slackware tuning options...

folkenfanel 10-22-2009 06:18 PM

I have it running in 19 seconds, measured by bootchart
 
19 seconds without CUPS
23 seconds with CUPS

I have done it in 14 seconds without the wireless network.

Custom 2.6.30.5 kernel, pretty much the same configuration as the huge kernel with all my specific drivers built in, with a 1000hz timer frequency, with x86_generic activated but also preempt, which I think gives me the performance gain. It IS very responsive even under high load (compiling software with 7 threads running and still able to run Firefox with Flash Player).

CONFIG_PREEMPT=y

It is still more than double the time Ubuntu takes to start (9 seconds), but they use prelinking and stuff like that.

I modified my init scripts and put what I don't need in rc.misc.

It can be done. Can it be done faster?

vinegaroon 10-22-2009 06:49 PM

Try grepping for sleep in rc.S.
There's at least one I've commented out without any problems.

hoanglong1712 10-24-2009 04:05 AM

slackware always run faster on my computer than any other OS
the most interesting part is that I could control what is running on my PC

grete 10-29-2009 06:02 AM

Another reason might be the configuration of the preemption model.
The stock Huge-SMP kernel i use as backup and my own built kernel
are configured as "server", not desktop.
This is what 95% of users want, and dont get with some distributions.
You might want a low latency desktop if you compile 3 kernels, watch 3 movies and listen to mp3 and host an 8 port quake game server at the same
time.
In most other cases, a server configuration is what you want. It is very responsive for everything you do at home. No reason for a low latency desktop just to look cool.
A quick check: use a low latency kernel and start dosbox. Dont play
anything, just leave it sitting at the dos prompt and watch your cpu.
Now do that with a server kernel. You will be astonished.
I'm not very sure about how that turns out in the average or "feeled"
speed of the whole system, but it might be a point.


All times are GMT -5. The time now is 12:41 PM.