homepage Welcome to WebmasterWorld Guest from 54.211.34.105
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Hardware and OS Related Technologies / Linux, Unix, and *nix like Operating Systems
Forum Library, Charter, Moderators: bakedjake

Linux, Unix, and *nix like Operating Systems Forum

This 34 message thread spans 2 pages: 34 ( [1] 2 > >     
Favorite command line tools?
littleman

WebmasterWorld Senior Member littleman us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 3:48 am on Aug 7, 2003 (gmt 0)

What are your top command line or term based tools and apps?

 

seindal

10+ Year Member



 
Msg#: 730 posted 9:46 am on Aug 7, 2003 (gmt 0)

Mostly the shell itself, with the ability to make complex commands with loops, tests and substitutions.

Mutt the mail reader.

grep for search in log files

tail for monitoring log files

tschild

10+ Year Member



 
Msg#: 730 posted 12:54 pm on Aug 7, 2003 (gmt 0)

grep, less, wget

Josk

10+ Year Member



 
Msg#: 730 posted 3:48 pm on Aug 7, 2003 (gmt 0)

shutdown?

shutdown -h now

dcheney

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 3:57 pm on Aug 7, 2003 (gmt 0)

grep, sed, tail

Mohamed_E

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 5:24 pm on Aug 7, 2003 (gmt 0)

  1. sed for surgery on multiple files
  2. awk to take a colon-separated list and make an HTML table
  3. perl for many other tasks, though I never developed the same familiarity with it as with the older tools

Nick_W

WebmasterWorld Senior Member nick_w us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 5:31 pm on Aug 7, 2003 (gmt 0)

  • Mutt
  • Lynx

I never got to grips with sed, what's it good for in everyday use?

Nick

bakedjake

WebmasterWorld Administrator bakedjake us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 5:31 pm on Aug 7, 2003 (gmt 0)

ssh - for connecting to remote sites

ncftp2 - ncftp is the coolest ftp client on the planet (version 2)

du - for checking disk space of directories

netstat, tcpdump - for debugging network connections

drbrain

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 5:42 pm on Aug 7, 2003 (gmt 0)

You mean that there are non-command line tools?

ruby is my swiss-army knife, and is combined with just about the rest of /bin, /usr/bin, and /usr/local/bin. Every now and then I use something in /sbin, /usr/sbin, /usr/local/sbin, and /usr/X11R6/bin.

Oh, and lets not forget the tools in ~/bin, and ~/.aliases :)

danny

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 6:41 am on Aug 8, 2003 (gmt 0)

ssh, rsync - for connecting to remote machines and maintaining mirrors (I use rsync for my web sites).

mutt, procmail, spamassassin - for email

vi - editing files

perl - one-liners for munging files

python - for longer scripts

Nick_W

WebmasterWorld Senior Member nick_w us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 6:51 am on Aug 8, 2003 (gmt 0)

Which reminds me

Vim!
ncftp
ssh

Nick

seindal

10+ Year Member



 
Msg#: 730 posted 8:08 am on Aug 8, 2003 (gmt 0)

All this discussion got me curious, so a ran this on my desktop machine

history ¦ awk '{print $2}' ¦ sort ¦ uniq -c ¦ sort -n

and god this:

484 ls
400 cd
394 perl
288 man
233 less
186 apt-cache
170 mysql
123 locate
119 make
104 dpkg
95 rm
87 grep
71 ps
64 tail
63 jed
63 cvs
57 bc
56 sh
56 mv
45 cat
42 wget
38 host
35 eog
34 xlsatoms
34 mysqldump
34 gcc
33 cp
31 rsync
31 cvs
30 ssh
30 find

As you can see, I do most of my file management in the shell. I never quite got used to graphical file managers, even though I use nautilus regularly.

Besides file management, there's some development work (perl, cvs, man, gcc, make), some server updates (rsync, ssh) and some maintenance (apt-cache, dpkg, mysqldump)

BTW, I keep a history of 5000 commands, hence the high numbers.

David

10+ Year Member



 
Msg#: 730 posted 1:01 pm on Aug 8, 2003 (gmt 0)


rpm
up2date
iptables
apt*

panic

10+ Year Member



 
Msg#: 730 posted 7:47 pm on Aug 8, 2003 (gmt 0)

killall -9

dcheney

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 8:10 pm on Aug 8, 2003 (gmt 0)

I never got to grips with sed, what's it good for in everyday use?

I use it mostly for transforming text files. For example, one script processes an error log from a major database application. Once grep is done, sed processes the results, turning them into a nice simple html page with the errors in an ordered list.

(sed basically allows you to take "vi" commands, write 'em out in a text file, and use that file to transform whatever file(s) you want.)

moltar

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 8:17 pm on Aug 8, 2003 (gmt 0)

vi
grep
tail
perl

dingman

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 8:24 pm on Aug 8, 2003 (gmt 0)

rig (Random Identity Generator)
find
file
lsof
emacs
tail
nohup
ssh
ps
less
links

EliteWeb

WebmasterWorld Senior Member eliteweb us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 8:27 pm on Aug 8, 2003 (gmt 0)

nmap
crack
john
tcpdump
lsof

mMmmMmm course those are a mix of binaries and such but still my favorite ;)

kevinpate

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 8:29 pm on Aug 8, 2003 (gmt 0)

For the uneducated amongst us, which may be just me, what is the wget command used for?

I've seen wget sumthinornuther in my logs but dinna really know what it was.

EliteWeb

WebmasterWorld Senior Member eliteweb us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 8:39 pm on Aug 8, 2003 (gmt 0)

man wget ;)

GNU Wget is a freely available network utility to retrieve
files from the World Wide Web, using HTTP (Hyper Text
Transfer Protocol) and FTP (File Transfer Protocol), the
two most widely used Internet protocols. It has many use-
ful features to make downloading easier, some of them
being...

panic

10+ Year Member



 
Msg#: 730 posted 10:36 pm on Aug 8, 2003 (gmt 0)

Did I mention that command line PHP owns? :)

-panic

Duckula

10+ Year Member



 
Msg#: 730 posted 11:49 am on Aug 9, 2003 (gmt 0)

sed basically allows you to take "vi" commands

Actually it's the inverse. In the old times the only way to edit a text file was with ed (not sed), until Billy Joy got sick of dealing with unbuffered lines and devised a VIsual ed :)

Oh, and...

ogg123
dselect
ssh, ssh-add, cvs
make install
locate
My countless bash scripts based on wget

<added>I stand corrected.</added>

Some more:

octave, maxima
python as a calculator
cal, calendar, date
fortune

[edited by: Duckula at 1:20 pm (utc) on Aug. 9, 2003]

seindal

10+ Year Member



 
Msg#: 730 posted 12:18 pm on Aug 9, 2003 (gmt 0)

Well, first there was ed, short for editor, with a user interface specially developed for paper terminals. It is still unbeaten in that sector :-)

When the first common teletypes (monochrome text-only monitors common in the 70s and early 80s) appeared, you could programmatically control a viewing area of more than one line, so ex/vi appeared. Ex was little more than a beefed up ed, and vi was the corresponding visual superstructure, the display engine, if you want. You could still run ex in commandline mode, just as ed, if you had to, but running vi on a paper terminal used up a lot of paper :-)

Sed was a variation of ed, and thus independent of ex/vi. Ed was actually rather powerful, especially wrt to search and replace functions, so when the pipe was invented back in the 70s (must have been Unix v4 or v5, because it was definitely there in v6), the ed internals was modified to work as a filter, hence sed, Stream EDitor. Given it was invented for use in pipes, in wonder why they didn't opt for ped, Pipe EDitor, but they didn't.

Grep is also a child of ed. The command in ed for finding and printing lines that match a regular expression is (literally) "g/RE/p" where RE is the Regular Expresssion. Grep is just that part separated from the ed interface. Later the extended grep (egrep) and the fixed string (fgrep) joined the family. Grep was also a part of Unix v6, so it is also from one of the very early version of Unix.

René

MonkeeSage

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 12:22 pm on Aug 9, 2003 (gmt 0)

df (list all mounted file devices w/ stats)
netstat -a (list all active sockets w/ packet info)
killall -KILL bin (kill the process bin and all its child processes (nb. quick and dirty and may leave zombies in some cases -- -TERM or -HUP is sometimes a better signal choice))
locate string1 [, string2] (search filesystem index for all instances of string string1, ...2, ...3, &c.)
command > something.txt (pipe output of command into file something.txt, creates file first if not exists)

Jordan

jamesa

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 8:06 pm on Aug 9, 2003 (gmt 0)

whoami (but it never quite gives me the answer I'm looking for :p)

But seriously, in addition to that and others mentioned already:

tail -f <-- great for watching log files in real time
vmstat
top
df
tar
scp
sftp
The whole FreeBSD Ports system!

Panaman

10+ Year Member



 
Msg#: 730 posted 5:54 am on Aug 13, 2003 (gmt 0)


r.m -rf /*

reboot

[edited by: littleman at 6:29 pm (utc) on Aug. 13, 2003]
[edit reason] put the dot into save somebody a world of hurt [/edit]

marcs

10+ Year Member



 
Msg#: 730 posted 5:55 am on Aug 13, 2003 (gmt 0)

grep, awk, sort, uniq, tail

jamesa

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 3:15 pm on Aug 13, 2003 (gmt 0)

rm -rf /*

^--- that deletes all the files on your hard disk.

I'm sure that was meant as a joke but I'd hate to see anyone who didn't know better give it a try. Always read the man pages, in this case: man rm

dingman

WebmasterWorld Senior Member 10+ Year Member



 
Msg#: 730 posted 3:32 pm on Aug 13, 2003 (gmt 0)

Reason number n++ not to run around as root all the time ;)

Of course, for most people all the important stuff is in their home directory and readable/writable by their normal user anyway.

littleman

WebmasterWorld Senior Member littleman us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 730 posted 6:28 pm on Aug 13, 2003 (gmt 0)

My connection was down all last night and I missed that one. Please do not post any damaging code.

This 34 message thread spans 2 pages: 34 ( [1] 2 > >
Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Hardware and OS Related Technologies / Linux, Unix, and *nix like Operating Systems
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved