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 |
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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
|
 |
10-08-2007, 02:56 PM
|
#1
|
LQ Newbie
Registered: Oct 2007
Location: Tennessee
Distribution: Mint
Posts: 11
Rep: 
|
DOS to Linux Translations
Ok I’m an old school DOS guy. Could some one help me translate how to do the following.
Write a batch file. - I think this is called a script?
Edit startup options like in good old autoexec.bat and config.sys – I’ve compiled my own kernel before – I’m still not real sure about module loading.
I’ve read more than one HowTo on module loading and they were rather confusing. There seemed to be more than one way to do this. Which is the old and what is the new? Right now I have to type in a very long sting in order to get my sound card to work on my old laptop. It would be nice to have it load at startup. Or at very least be able to write a batch, excuse me, script to do this.
I’m sure there are other things but for now that’s it.
Last edited by avadondragon; 10-08-2007 at 02:58 PM.
|
|
|
10-08-2007, 03:08 PM
|
#2
|
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809
|
Remember, Unix came first. I'm pretty sure that DOS was based on Unix. So our school is older than yours...
"shell script" is the buzzword you're looking for--I guess to distinguish from Perl script, etc.
tldp.org has all manner of good--and free--documents. I would start with "Bash Guide for Beginners" by Machtelt Garrels.
The exact nature of the various startup files depends on the distribution....Since Slackware is targeted to relatively sophiticated users, I expect there is some useful documentation.
|
|
|
10-08-2007, 03:13 PM
|
#3
|
Senior Member
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Rep:
|
1) Yep, batch file sorta equals script. Not exactly though. Batch file is to shell script as Pinto is to Camaro.
2) There are indeed two ways to load modules. I'm not sure if there is a chronological relationship between the two, but one way is often seen as 'safer'. The first is to use 'insmod module_name' to load a module and 'rmmod module_name' to unload it. The "safer" way is to use "modprobe module_name" to load a module and "modprobe -r module_name" to unload it. The difference? modprobe checks module dependencies - if you want to load module A, and A requires module B, then "modprobe A" will also load B whereas "insmod A" will not.
3) If you want to write a script to load the module at startup you need to put script in /etc/rc.d and then create a symlink to it in /etc/rc.3 and /etc/rc.5
|
|
|
10-08-2007, 03:21 PM
|
#4
|
Senior Member
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Rep:
|
Oops, It seems Slack is a bit different in this regard. It would be /etc/rc.3 and /etc/rc.4 - they use runlevel 4 as the graphical level, not 5. If that sounds like gibberish, don't worry. Runlevels are kinda like "modes" that you can run your computer in. 3 is text-mode and 4 is graphical mode.
By the way, what part of South Carolina are you from (of course, that is if you don't mind saying over the net). Home for me is just outside Columbia in a town called Lexington, but I'm away at college in Charleston.
|
|
|
10-08-2007, 03:25 PM
|
#5
|
LQ Newbie
Registered: Oct 2007
Location: Tennessee
Distribution: Mint
Posts: 11
Original Poster
Rep: 
|
Thank you very much. Your info is most helpful.
Also with the old-school dos comment I was just trying to emphasize I predate the windows GUI not UNIX.
I live in Scumter. Oh I meant Sumter. I work in Columbia.
Last edited by avadondragon; 10-08-2007 at 03:30 PM.
|
|
|
10-08-2007, 05:03 PM
|
#6
|
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809
|
Quote:
Originally Posted by avadondragon
Also with the old-school dos comment I was just trying to emphasize I predate the windows GUI not UNIX. 
|
I predate ALL GUIs.......so there!!!..... 
|
|
|
10-08-2007, 06:34 PM
|
#7
|
LQ Newbie
Registered: Oct 2007
Location: Tennessee
Distribution: Mint
Posts: 11
Original Poster
Rep: 
|
LoL
Well my FIRST pc was a Radio Shack TRS-80 Color computer running at just under 1MHz and sporting a WOPING 32k of RAM. Its OS? The "Basic" programing language!
I loved the sounds my audio casset tape player made as I loaded programs up.
But yes there were already systems that ran Unix even then.
Last edited by avadondragon; 10-08-2007 at 06:35 PM.
|
|
|
10-08-2007, 06:36 PM
|
#8
|
Senior Member
Registered: Mar 2003
Location: Following the white rabbit
Distribution: Slackware64 -current
Posts: 2,300
Rep:
|
In Slackware the best place to call up any user desired commands, module loads, or bash scripts during boot is from /etc/rc.d/rc.local
|
|
|
10-08-2007, 06:53 PM
|
#9
|
Senior Member
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Rep: 
|
I Google "Dos and Linux commands similarity"
and the first site comes up with this
|
|
|
10-08-2007, 07:04 PM
|
#10
|
LQ Guru
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.x
Posts: 18,444
|
Just for fun (& off topic), my first paid prog job was on Sinclair Spectrum, rubber keyboard, casstte loader. Not sure about RAM, but 8 or 16K rings a bell.

|
|
|
10-08-2007, 08:17 PM
|
#11
|
LQ Newbie
Registered: Oct 2007
Location: Tennessee
Distribution: Mint
Posts: 11
Original Poster
Rep: 
|
Quote:
Originally Posted by masonm
In Slackware the best place to call up any user desired commands, module loads, or bash scripts during boot is from /etc/rc.d/rc.local
|
Masonm – That is exactly the info I needed to know. Thank you very much.
Quote:
Originally Posted by saikee
I Google "Dos and Linux commands similarity"
and the first site comes up with this
|
Saikee – I’ve run that search before. Very useful reference though. There are a few commands on there that I either didn’t know or just forgot. Like “free” I never remember that one for some reason.
Quote:
Originally Posted by chrism01
Just for fun (& off topic), my first paid prog job was on Sinclair Spectrum, rubber keyboard, casstte loader. Not sure about RAM, but 8 or 16K rings a bell.

|
Chrism – Yep the Sinclair Spectrum came in two versions one of which had only 16K but it was a speed demon at 3.5MHz! You Europeans and your fancy toys! 
|
|
|
10-15-2007, 05:18 PM
|
#12
|
Senior Member
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
|
Quote:
Originally Posted by pixellany
I predate ALL GUIs.......so there!!!..... 
|
Me too!
But perhaps not by as much as we think -- in the early to mid '50's MIT's Univac had a TV screen that I saw used to play Tic-Tac-Toe w/ visitors. What I'm not sure about was how it was driven & controlled.
|
|
|
All times are GMT -5. The time now is 09:42 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|