Author Topic: Something I dont get with all these different versions of Linux  (Read 1010 times)

lazygamer

  • Member
  • **
  • Posts: 1,146
  • Kudos: 0
Something I dont get with all these different versions of Linux
« Reply #15 on: 29 August 2002, 07:53 »
Hmmm interesting. So you mean a person could make Mandrake run almost as fast as Slackware, if he knew what he was doing?
For every hot Lesbian you see in a porno video, there is a fat, butch-like, or just downright ugly lesbian beeyotch marching in a gay pride parade, or bitching about same sex marriages. -Lazygamer on homosexuality

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #16 on: 29 August 2002, 08:32 »
Of course. Remember, everything is open for modification in Linux and most of it ain't rocket science. Just requires a little up front research and learning (and a couple of brain cells to rub together certainly wouldn't hurt).

NOTE: the brain cell remark is not targeted to you, just a general statement.

Basic boot sequence on most Linuxes:

1) System BIOS
2) Master Boot Record
3) Boot Loader (GRUB or LILO)
4) Kernel (hardware detection and drivers for said hardware)
5) init/run levels (similar to SERVICES.EXE/Services in WinNT/2K/XP)

Now the first 4 steps should not take long on any Linux system. Step 5 would be where the majority of the boot time would take place.

The "init" program's configuration file should be "/etc/inittab". This file itself should not usually require modification and if you screw it up your system will not boot. However, within that configuration file is where the "run levels" are defined, including the default run level.

Run levels:
0 - halt
1 - single user
2-4 - user defined
5 - Xwindows login prompt
6 - reboot

If your system starts up with a graphical logon prompt then your "initdefault" is set to 5.

Now the "inittab" file defines the directories where the service scripts reside that should be started/stopped when entering a runlevel.  Usually all of the scripts reside in the
"/etc/rc.d/init.d" or the "/etc/init.d" directory. There should be one script for each service, written to start or stop the service based on whether the script was called with the "start" or "stop" parameter. This directory is just a storage directory.  There will be another directory for each of the individual run levels. Usually either:

/etc/rc.d/rc0.d
/etc/rc.d/rc1.d
/etc/rc.d/rc2.d
/etc/rc.d/rc3.d
/etc/rc.d/rc4.d
/etc/rc.d/rc5.d
/etc/rc.d/rc6.d

or:

/etc/rc0.d
/etc/rc1.d
/etc/rc2.d
/etc/rc3.d
/etc/rc4.d
/etc/rc5.d
/etc/rc5.d

In each of those directories you will find many symbolic links to the service scripts in "/etc/rc.d/init.d".  The name of the symbolic links are significant as they signify whether the  service should be "started" or "stopped" and which order the scripts should be executed in.  Take the "sshd" service for example.  Say you have a "/etc/rc.d/init.d/sshd" script that is used to control the sshd server service.  You want it to start when your system boots. Since you have your initdefault set to 5 (graphical login) you would create a symbolic link to that file like so:

ln -s /etc/rc.d/init.d/sshd /etc/rc.d/rc5.d/S60sshd

which creates a symbolic link called "/etc/rc.d/rc5.d/S60sshd".  Notice the "S60" that I prepended to the script name. This is significant because the "S" means I want theservice "started" when entering run level "5". Also notice the number "60" between the "S" and the script name. This is also significant because I do not want the script to start until scripts with lower 2 digit numbers have been started, but before scripts with higher 2 digit numbers have been started.

In addition to the "S" you can prepend a "K" which would "stop" a service upon entering the run level. 2 digit numbers should also be used in the naming for the "stop" scripts.

Again, this is the manual method of turning on/off services. It is exactly what "tksysv" and the "chkconfig" commands will do but with a more intuitive interface.

Now since you have initdefault set to "5" after all of the services have started from the /etc/rc.d/init.d/rc5.d directory your XDM/KDM startup script will run. Depending on what is started in that script could also make difference in startup times between distros. You should find the name graphical logon script that is executed in your /etc/inittab configuration file.  Check out that script and modify it if you don't like all that it performs.  In RedHat the script that kicks off the graphical login is "/etc/X11/prefdm". Other distros probably use a different script.

I suggest you take a look at the configuration files and the scripts in /etc/rc.d/init.d to see how the stuff works.  There really isn't a lot to it.

For further reading search for "linux boot process" in Google.  Or if you want more specific information about a specific distro substitute "linux" with "distroname".

[ August 29, 2002: Message edited by: VoidMain ]

Someone please remove this account. Thanks...

Bazoukas

  • Member
  • **
  • Posts: 866
  • Kudos: 140
    • http://whitehouse.com
Something I dont get with all these different versions of Linux
« Reply #17 on: 29 August 2002, 10:12 »
One thing i would suggest is to watch carefully the Boot messages during boot or shutdowntime.


  Everytime i look at it, it makes more and more sense.

BTW VoidMan, I sure would love to have you as a Teacher at College man.

[ August 29, 2002: Message edited by: bazoukas ]

[ August 29, 2002: Message edited by: bazoukas ]

Yeah

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #18 on: 29 August 2002, 11:02 »
quote:
Originally posted by bazoukas:

BTW VoidMan, I sure would love to have you as a Teacher at College man.



That could be arranged. Got any openings?
Someone please remove this account. Thanks...

Bazoukas

  • Member
  • **
  • Posts: 866
  • Kudos: 140
    • http://whitehouse.com
Something I dont get with all these different versions of Linux
« Reply #19 on: 29 August 2002, 11:18 »
At the coolege I used to go at Prudue Calumet (NOT lafayete) they were out of teachers and they had seniors teaching C++. Thats a winner. You would hate it though. They dont teach nothing X related.

 The one am going now i doubt it if they would pay you enough money.

 But when I tranfer back at Brooklyn College, now there you would love it. Assembly, compilers, Unix,C# you name it.


  I dont know where you live, but if you dont got any kids or wife,  shit,  NYC is one FUN place to be. Besides i could use a roomate     :D  

]errr the word shit was not meant to be like kids+wife=shit.

[ August 29, 2002: Message edited by: bazoukas ]

Yeah

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #20 on: 29 August 2002, 11:27 »
Well, I've got the wife and the kids and they are one of the reasons I passed up a teaching job that would have required me to move to Mississippi. I would have been teaching basic programming (PDL, Flow Charts, Software Life Cycle, documents etc), as well as ASM, C, ADA, FORTRAN and COBOL. Now this was about 6 years ago, I certainly hope COBOL is not still on their list!
Someone please remove this account. Thanks...

Bazoukas

  • Member
  • **
  • Posts: 866
  • Kudos: 140
    • http://whitehouse.com
Something I dont get with all these different versions of Linux
« Reply #21 on: 29 August 2002, 11:42 »
ohhhhh you would be suprised about Cobol.

 they still do teach it  :(  
Students are avoiding it like the plague though.

  And from what i can tell the only companies running on Cobol are old companies or/and companies that are cheap like hell and they have machinery from the early 70's. Like the company I used to work at.
Yeah

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #22 on: 29 August 2002, 11:46 »
Yeah we still had COBOL floating around on our mainframes at the last two places I worked, although a lot of it got wiped out during the big Y2K risk analysis. I'm sure some companies are still writing COBOL but there can't be many.
Someone please remove this account. Thanks...

Bazoukas

  • Member
  • **
  • Posts: 866
  • Kudos: 140
    • http://whitehouse.com
Something I dont get with all these different versions of Linux
« Reply #23 on: 29 August 2002, 11:52 »
Three languages that never moved my interest is Cobol, Visual Basic and HTML (Fotran though I do wanna learn.)
 

 Mainly because its not as trim as c++ is.

 I did some VB, passing values to variables or doing functions, damn, it was like writing a 5 page journal. And HTML looks even worst even though it takes few hours to learn.

 I will pick HTML at the same time when am learning PHP.
Yeah

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #24 on: 29 August 2002, 12:21 »
I really haven't done a lot of "compiled" programming lately. I enjoy scripting and web programming more than anything (shell, Perl, PHP, HTML, etc) as I have been more into administration than application programming over the last several years.

VB is the devil. I've done a bit of VB programming and it has to be the worst language ever. Maybe the biggest reason I hate it is it locks you in to Windows. HTML/PHP/Perl really are fun. I don't know how anyone could not like them, instant gratification. But of course you'll want to combine them with SQL and tie into databases which maximizes satisfaction by being dynamic.

Most apps I write today I prefer to be web based if at all possible so they can be accessed from anywhere by any OS/browser. Standalone applications for me just are not fun. Too much like work (I was an applications programming team leader for a few years).
Someone please remove this account. Thanks...

Bazoukas

  • Member
  • **
  • Posts: 866
  • Kudos: 140
    • http://whitehouse.com
Something I dont get with all these different versions of Linux
« Reply #25 on: 29 August 2002, 12:30 »
You are along the line that one of my teachers is. He started out as a programer, he even worked for NASA for a while, but he prefers to work as an Admin now. According to him programing and multidimensional Arryas, take their toll on a man's hair after few decades lol.

 For the HTML and PHP languages i dont know why i never got into them.
 I think it was more along the lines that "I need to do C++ cause its hard so i can prove to my self that i can do it, even though i am a psych major".

[ August 29, 2002: Message edited by: bazoukas ]

Yeah

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #26 on: 29 August 2002, 12:45 »
Certainly knowing compiled languages such as C++ is a huge advantage and I would *never* discourage learning them. It makes all the other scripting languages baby stuff. And many times I need to whip up small C programs to use within scripts when a script isn't quite enough to do a task.

Sometimes it makes more sense to do a portion in C/C++, even with web programming. While the other people say something can't be done, you can chug right along and do that task and leave them in the dust.
Someone please remove this account. Thanks...

Bazoukas

  • Member
  • **
  • Posts: 866
  • Kudos: 140
    • http://whitehouse.com
Something I dont get with all these different versions of Linux
« Reply #27 on: 29 August 2002, 12:52 »
ohhh I didnt know C++ can be used on web programing as well!!!!!

 i thought you could only do apps for desktops or apps for use over a local  network.


 te he he. Good stuff.
Yeah

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Something I dont get with all these different versions of Linux
« Reply #28 on: 29 August 2002, 20:25 »
You can actually use any language you want for CGI programming.

[ August 29, 2002: Message edited by: VoidMain ]

Someone please remove this account. Thanks...