Register a domain and help support LQ
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 01-03-2006, 05:05 AM   #1
LQ Newbie
Registered: Jan 2006
Posts: 3

Rep: Reputation: 0
insmod command variables in a script

What does the "$*" and "|| exit 1" in the command:

insmod ./$module.o $* || exit 1

mean? Google-ing for "linux $*" or "insmod $*" doesn't seem to uncover any answers. This is part of a script to load a module in 2.4.


Last edited by fpb; 01-03-2006 at 05:15 AM.
Old 01-03-2006, 05:33 AM   #2
Registered: Jan 2005
Location: The grassy knoll
Distribution: Slackware,Debian
Posts: 192

Rep: Reputation: 31
$* are the positional parameters (or command line arguments) to the script.
example: script arg1 arg2
arg1 and arg2 get put in $*

|| is the 'or' operator. If the insmod fails, the script exits with a code of 1, which is the standard exit code for failure. If the insmod succeeds the exit 1 is skipped.
Old 01-03-2006, 07:29 PM   #3
LQ Newbie
Registered: Jan 2006
Posts: 3

Original Poster
Rep: Reputation: 0
Cool. That was easy to understand & very helpful.

Originally I'd thought it was the Makefile special macro $* that is the prefix shared by target & dependent files, but that doesn't make sense in the script of course.

Thanks a lot vls! Happy New Year!


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 On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
URGENT : pb with insmod command pierre44 Linux - Newbie 1 07-11-2005 06:59 AM
Passing variables from AWK script to my shell script BigLarry Programming 1 06-12-2004 04:32 AM
missing insmod command caesarkim Linux - Networking 2 05-20-2004 02:49 PM
insmod command ...........? hamoksh Linux - Newbie 3 07-16-2003 03:41 AM
insmod command under RH 8.0 jpohara Linux - Newbie 1 10-07-2002 09:59 AM

All times are GMT -5. The time now is 05:40 AM.

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