Re: OT: Shell Script

This WebDNA talk-list message is from

2005


It keeps the original formatting.
numero = 61658
interpreted = N
texte = Clint Davis wrote: > Can anyone provide an example of a shell script that would insert three > entries into the /etc/hosts file and perform `lookupd -flushcache` ? Don't run random shell scripts that someone posts to a public listserv without understanding what they do (typically by running them one line at a time with an unpriveleged account, i.e. *not* root). This should be a good example: > #!/bin/sh > # call like: > # scriptname entry1 entry2 entry3 > echo %1 >> /etc/hosts > echo %2 >> /etc/hosts > echo %3 >> /etc/hosts > lookupd -flushcache Get out to your favorite independent bookstore and buy a Unix administration book (O'Reilly has a few), since you should be able to do simple things like this before you seriously try and administer a *nix box... HTH John -- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4501 Forbes Boulevard Suite H Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5748 ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: OT: Shell Script ( John Peacock 2005)
  2. OT: Shell Script ( Clint Davis 2005)
Clint Davis wrote: > Can anyone provide an example of a shell script that would insert three > entries into the /etc/hosts file and perform `lookupd -flushcache` ? Don't run random shell scripts that someone posts to a public listserv without understanding what they do (typically by running them one line at a time with an unpriveleged account, i.e. *not* root). This should be a good example: > #!/bin/sh > # call like: > # scriptname entry1 entry2 entry3 > echo %1 >> /etc/hosts > echo %2 >> /etc/hosts > echo %3 >> /etc/hosts > lookupd -flushcache Get out to your favorite independent bookstore and buy a Unix administration book (O'Reilly has a few), since you should be able to do simple things like this before you seriously try and administer a *nix box... HTH John -- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4501 Forbes Boulevard Suite H Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5748 ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ John Peacock

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Storebuilder Seems to have just died (2003) ReturnRaw and redirect (1997) what servers are supported for Typhoon? (1997) test (2005) [WebDNA] Can't see were it's wrong.... (2017) WC1.6 to WC2 date formatting (1997) [OT]Target Links (advanced??) (2001) (1997) WebTen and WebCat (1997) [WebDNA] group searching not working as expected. (2010) My X-Mas Wish (1999) Re:1 cent answer? (1998) Search (1997) Almost a there but..bye bye NetCloak (1997) ssl/empty cart problem (2003) Hyperboard/bulletin board available (1998) RE: Re:Signal Raised (1997) Nested tags count question (1997) 'does not contain' operator needed ... (1997) Add to a filename in multifile upload (2002)