Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (4) </ 1 [2] 3 4 >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: linuxrc, How to use bash in linuxrc not ash?< Next Oldest | Next Newest >
MrUmunhum Offline





Group: Members
Posts: 23
Joined: Feb. 2006
Posted: Nov. 21 2006,21:13 QUOTE

Quote (mikshaw @ Nov. 21 2006,15:31)
These issues are not a result of ash being broken, but are because bash has added features that are not available in ash.  The string manipulation above is an example of bash-specific script.

If you do a man on ash and go to 'Parameter Expansion' section, these formats are meant to be supported.  But they doing work.
Back to top
Profile PM 
^thehatsrule^ Offline





Group: Members
Posts: 3275
Joined: July 2006
Posted: Nov. 21 2006,21:21 QUOTE

Hm, interesting - my next guess is that the included ash binary is not the same version as the manpage you are looking at, or its not compiled in, etc. (since I haven't seen any startup scripts using it, I wouldn't be surprised).

Guess another alternative is to replace ash with one that works to how you want it to.

Another thing, can you log the boot processes?  Anyways, did you try running a dummy script inside an ash terminal?
Back to top
Profile PM 
MrUmunhum Offline





Group: Members
Posts: 23
Joined: Feb. 2006
Posted: Nov. 21 2006,21:23 QUOTE

Quote (^thehatsrule^ @ Nov. 21 2006,16:03)
Ah yes.. the 'bash-isms'

If you really don't care about about speed and efficiency I suppose you could try to use bash instead.

Otherwise, I'd suggest for you to replace whatever scripting you're doing with replacement commands or use another implementation.  If you decide to go this way, you could paste out your script (or snippets of) to show what you're trying to do with the code and we can try to help.

I am trying to use bash because ash is so limited.

Here is my added code:
Quote

case "$CMDLINE" in *nfs=*)
      set -x;
     $INSMOD /modules/sunrpc.o
     $INSMOD /modules/lockd.o
     $INSMOD /modules/nfs.o
     lsmod
     NOIDERAID="yes";
     NOCD="yes";
#      NFS_SERVER="${CMDLINE##*nfs=}";
#      NFS_SERVER="${NFS_SERVER%%[     ]*}";
     echo NFS_Server="${NFS_SERVER}";
     mount  -t nfs 10.1.1.12:/tftpboot/DSL /KNOPPIX
     set +x;  ;; esac
Back to top
Profile PM 
MrUmunhum Offline





Group: Members
Posts: 23
Joined: Feb. 2006
Posted: Nov. 21 2006,21:28 QUOTE

Quote (^thehatsrule^ @ Nov. 21 2006,16:21)
Another thing, can you log the boot processes?  Anyways, did you try running a dummy script inside an ash terminal?

What do you mean by an 'ash terminal'?
Back to top
Profile PM 
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Nov. 21 2006,21:45 QUOTE

"aterm -e ash" should give you an ash terminal.

Quote
If you do a man on ash and go to 'Parameter Expansion' section, these formats are meant to be supported.

It might be an older version of ash in DSL?  Just guessing.


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
18 replies since Nov. 21 2006,12:47 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (4) </ 1 [2] 3 4 >/
reply to topic new topic new poll
Quick Reply: linuxrc

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code