<?xml version="1.0" encoding="UTF-8"?>

<rss version="2.0" xmlns:blogChannel="http://backend.userland.com/blogChannelModule">

<channel>
<title>Little Known Tips and Tricks... in All Things Unix</title>
<link>http://www.dslreports.com/forum/r6178008</link>
<description></description>
<language>en</language>
<pubDate>Sat, 28 Nov 2009 06:53:56 EDT</pubDate>
<lastBuildDate>Sat, 28 Nov 2009 06:53:56 EDT</lastBuildDate>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,18664056</link>
<description><![CDATA[<A HREF="/useremail/u/274066"><b>FastEddie</b></A> : <BR><SMALL><SMALL>Pssst! Look over to your left at the Forum Links </SMALL> </SMALL><br><BR>                                                                      <br>[attachment=1]<br><BR><br><SMALL>--<br><A HREF="http://lebop.home.mindspring.com/hi/audience.html">Here's To You</A></SMALL><div class="borderless"><TABLE WIDTH=95% align=center border=0 CELLPADDING=4"><TR><TD ALIGN=CENTER VALIGN=CENTER BGCOLOR=#000000 nwrap COLSPAN=2 WIDTH=66%><A HREF="/speak/slideshow/18664056?c=1187967&ret=L2ZvcnVtL3I2MTc4MDA4LnhtbA%3D%3D"><IMG TITLE="38453 bytes" BORDER=0 WIDTH=262 HEIGHT=343 SRC="/r0/download/1187967~d0ca7fc086cdaba0d60d55baca21aea9/snapshot23.png"></A><br>Map for those that can't find this thread</TD></TABLE></div>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,18664056</guid>
<pubDate>Fri, 13 Jul 2007 09:47:40 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,18663802</link>
<description><![CDATA[<A HREF="/useremail/u/633982"><b>alien9999999</b></A> : hmm, strange... it should be sticky...<br><br>you better sitemark it, just in case<br><SMALL>--<br>Alien is my name and headbiting is my game.</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,18663802</guid>
<pubDate>Fri, 13 Jul 2007 08:51:22 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,18662246</link>
<description><![CDATA[<A HREF="/useremail/u/652505"><b>Happyrat</b></A> : Why is this thread no longer sticky?  Most of the info presented in this thread is timeless...<br><SMALL>--<br>:) Satan Loves You... :) &raquo;<A HREF="http://fuzzyrat.com" >fuzzyrat.com</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,18662246</guid>
<pubDate>Thu, 12 Jul 2007 22:49:19 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,18620350</link>
<description><![CDATA[<A HREF="/useremail/u/925666"><b>armitage</b></A> : I dont recall where or when I found this, but just in case that you cat a binary file while in a terminal (before starting X), hit - <br><br>ctrl-v ESC-C<br><br>and that'll reset your terminal to normal...<br><br>haven't seen this work in FreeBSD though (but I can cat a bin file and still have a normal term in BSD though).<br><SMALL>--<br>Windows? It's a pack of instant noodles. Convenient, but not very healthy. Linux? Well, linux is the kitchen.</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,18620350</guid>
<pubDate>Thu, 05 Jul 2007 18:56:31 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,18551497</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Hate when your cursor disappears?<br><br>tried a reset? clear?<br><br>invisible cursor no more!<br><br><textarea name="code" class="text" cols=50 rows=10>tput ve&#012;</textarea><!--end code block-->]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,18551497</guid>
<pubDate>Fri, 22 Jun 2007 17:38:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,18333502</link>
<description><![CDATA[<A HREF="/useremail/u/633982"><b>alien9999999</b></A> : i don't want to sound arrogant, but i feel this might be usefull: &raquo;<A HREF="/forum/remark,18332818">Installing IPv6 Server</A><br><SMALL>--<br>Alien is my name and headbiting is my game.</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,18333502</guid>
<pubDate>Mon, 14 May 2007 16:29:01 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,17984928</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : No offense  dom6791 <A HREF="/useremail/u/521190"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>, but that's just crazy.  There's no need to do that.<br><br>ls -d */ <br><br>That's it.<br><br>Also,  your for loop will only work so long as the directory names have no spaces in them.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17984928</guid>
<pubDate>Sun, 11 Mar 2007 19:56:59 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,17968095</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : In the event someone ever wanted to list only directories:<br><br><STRIKE>for i in * ; do if [ -d $i ]; then echo $i ; fi ; done</STRIKE><br><br>hohumdedumdum, True! :)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17968095</guid>
<pubDate>Thu, 08 Mar 2007 17:51:44 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,17858708</link>
<description><![CDATA[<A HREF="/useremail/u/864682"><b>ghost16825</b></A> : Gentoo installer/user tip:<br><br>This is more or less a RTFM tip rather than anything really brilliant. (Yes, I admit it - I occasionally do read the manual)<br><br>What should really be more prominent in the Official Gentoo docs is the elog system - logs info, warning messages etc when emerging.<br><br><div class="code"><PRE><span class="codetext">#In your /etc/make.conf<br> <br>#The default save directory for these logs is /var/log/portage/elog/<br>PORTAGE_ELOG_CLASSES="info warn error log qa"<br>PORTAGE_ELOG_SYSTEM="save"<br>#or save_summary for all the critical information in one file rather than separately.</SPAN></PRE></DIV>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17858708</guid>
<pubDate>Mon, 19 Feb 2007 00:10:18 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,17800792</link>
<description><![CDATA[<A HREF="/useremail/u/960611"><b>weeksben1</b></A> : Just want to say thanks for the tips and tricks.  Its great for showing us *nix rookies, some new (at least to us) stuff.<br><SMALL>--<br>Ben WeeksNetwork AdminNovell CNA NW3.2/4.x/5.xNetwork + Certified</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17800792</guid>
<pubDate>Fri, 09 Feb 2007 09:18:11 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,17736414</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : Didnt see this one in the list<br><br>If you have many files in a directory that you want to execute consecutively, but dont want the hassle of manually running one at a time:<br><br>find /tmp/syncfiles -name 'sync*' -exec sh {} \;<br><br>This will find all files that begin with 'sync' in the /tmp/syncfiles directory and execute one at a time. This saved me lots of time since it takes 7 hours sometimes. Now I can just start it and walk away. :)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17736414</guid>
<pubDate>Tue, 30 Jan 2007 09:26:24 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,17488522</link>
<description><![CDATA[<A HREF="/useremail/u/168087"><b>Daniel</b></A> : With <A HREF="http://dmiessler.com/study/nix/commands/lsof">lsof</A> you can use the -t and -u switches to kill everything a user has open:<br><div class="code"><PRE><span class="codetext">kill -9 `lsof -t -u daniel`</SPAN></PRE></DIV>Use with care. ;) ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17488522</guid>
<pubDate>Tue, 19 Dec 2006 15:11:01 EDT</pubDate>
</item>

<item>
<title>Re: Start a script based on reception of a file</title>
<link>http://www.dslreports.com/forum/remark,17414665</link>
<description><![CDATA[<A HREF="/useremail/u/246096"><b>yock</b></A> : <div class="bquote"><SMALL>said by  timcuth <A HREF="/useremail/u/203572"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> :</SMALL><br><br>I really think this thread should be edited into the ATU FAQ, as it is getting to be next to impossible to find anything specific in such a long thread.</DIV>That's a great idea. If users feel so inclined, they can submit their FAQ suggestions to <A HREF="http://www.dslreports.com/faq/unixdsl/edit">this page</A> and the system will IM the FAQ editors that there are new suggestions for the FAQ. In fact,  Maxo <A HREF="/useremail/u/715380"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> sent us one just today.<br><br> No_Strings <A HREF="/useremail/u/520919"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> and I are slowly making our way through the FAQ in a massive cleanup effort, so anything you guys can add would be welcome.<br><SMALL>--<br><A HREF="http://allthingsunix.org/wiki/Main_Page">Wiki Wiki</A><BR>Laughter is the closest distance between two people. --Victor Borge</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17414665</guid>
<pubDate>Thu, 07 Dec 2006 12:22:55 EDT</pubDate>
</item>

<item>
<title>Start a script based on reception of a file</title>
<link>http://www.dslreports.com/forum/remark,17414274</link>
<description><![CDATA[<A HREF="/useremail/u/203572"><b>timcuth</b></A> : I don't know whether this already has been posted. I really think this thread should be edited into the ATU FAQ, as it is getting to be next to impossible to find anything specific in such a long thread.<br><br>Anyway, this week at work I was required to initiate a batch script upon reception of an FTP'ed file, rather than scheduling the job at a regular time. I did a Google search and then added my own twists, coming up with a very nice solution.<br><br>Since the batch script runs for about 10 minutes, I decided to check for the incoming file every 15 minutes during the range of times when the file might arrive (3 AM - 9 AM, Tue - Sat):<br><br>00,15,30,45 3-9 * * 2-6 /path/check_for_file.sh<br><br>check_for_file.sh runs the UNIX find command to look for the incoming file with a timestamp newer than the output file that is created by the batch script. When the newer input file is found, the find command starts the batch script:<br><br>find /expimp/blah -name input_file.txt -newer /path/output_file.txt -exec /path/batch_script.sh \;<br><br>Works like a charm!<br><br>Tim<br><br><SMALL>--<br><I>The shortest sentence is, "I am". The longest is, "I do".</I><br><B><A HREF="http://www.tdprojecthope.com/"> ~ Project Hope ~ </B></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,17414274</guid>
<pubDate>Thu, 07 Dec 2006 11:08:53 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16566688</link>
<description><![CDATA[<A HREF="/useremail/u/203572"><b>timcuth</b></A> : Here is the info I was asking about:<br><br>When a binary executable file has been given the setuid attribute, normal users on the system can execute this file and gain the privileges of the user who owns the file (commonly root) within the created process. When root privileges have been gained within the process, the application can then perform tasks on the system that regular users normally would be restricted from doing. The invoking user will be prohibited by the system from altering the new process in any way, such as by using ptrace, LD_LIBRARY_PATH or sending signals to it (signals from the terminal will still be accepted, however).<br><br>&raquo;<A HREF="http://en.wikipedia.org/wiki/Setuid" >en.wikipedia.org/wiki/Setuid</A><br><br>Apparently, the Oracle program I set this on then allows other users to execute it with the privileges of oracle, not root.<br><br>Tim<br><SMALL>--<br><I>The shortest sentence is, "I am". The longest is, "I do".</I><br><B><A HREF="http://www.tdprojecthope.com/"> ~ Project Hope ~ </B></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16566688</guid>
<pubDate>Mon, 24 Jul 2006 15:34:08 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16566617</link>
<description><![CDATA[<A HREF="/useremail/u/203572"><b>timcuth</b></A> : <div class="bquote"><SMALL>said by  gatessux <A HREF="/useremail/u/285748"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> :</SMALL><br><br>Sorry, I should of read all the replies before posting this... <br>Good one, I just wanted to furthur help out...<br>It's binary, as stated above, you need to do it 3 times for each, User of the file, Group that has rights, and Others (everyone else).<br><br>Here's a cheat table...<br>------------<br>RWX<br>000 = 0, no rights<br>001 = 1, eXecute<br>010 = 2, Write<br>011 = 3, Write/eXecute<br>100 = 4, Read<br>101 = 5, Read/eXecute<br>110 = 6, Read/Write<br>111 = 7, Read/Write/eXecute<br><br>(if it's 0 it's false, if it's 1, it's true)<br><br>Also:<br>chown = change owner, chgrp = change group<br>A great reference can be found here as well :<br>&raquo;<A HREF="http://www.tldp.org/LDP/intro-linux/html/sect_03_04.html" >www.tldp.org/LDP/intro-linux/htm&middot;&middot;&middot;_04.html</A><br><br>Thanks...<br> </DIV>Could someone expand on the above info to explain "sticky bits"? I have to use them in my job as an Oracle DBA, and I follow the instructions and get them correctly, but I have no idea what they mean or what exactly I am doing.<br><br>E.g., some Oracle database programs have to have "chmod 7455" in order to work. If you then display the program, you see "-rwsr-s---". (I am not sure my chmod command example and my mode display match, exactly).<br><br>I think it has something to do with the programs running with root authority, but I don't understand the why or the how.<br><br>Thanks,<br>Tim<br><br>PS - I knew even less than I thought. The actual chmod command was "chmod 4755" (not 7455) and it is called "setuid". My system administrator saw me do it and he was the one who called it "the sticky bit".<br><br>Anyway, I found some info in this article: &raquo;<A HREF="http://en.wikipedia.org/wiki/Chmod" >en.wikipedia.org/wiki/Chmod</A><br><br>Sorry.<br><SMALL>--<br><I>The shortest sentence is, "I am". The longest is, "I do".</I><br><B><A HREF="http://www.tdprojecthope.com/"> ~ Project Hope ~ </B></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16566617</guid>
<pubDate>Mon, 24 Jul 2006 15:23:12 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16275735</link>
<description><![CDATA[<A HREF="/useremail/u/246096"><b>yock</b></A> : <div class="bquote"><SMALL>said by  Steve <A HREF="/useremail/u/340145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> :</SMALL><br><br>Why not:<br><div class="code"><PRE><span class="codetext">if cal $mon $year | grep -qw $day<br>then<br>    echo "do stuff here if it's a valid date"<br>else<br>    echo "invalid date entered"<br>fi</SPAN></PRE></DIV>No need for the variable set when you can check for the result directly in the "if"<br><br>Steve <SMALL>&mdash; who nevertheless would have not thought to do it this clever way</SMALL><br><br> </DIV>I think a *LOT* of people forget about return codes when shell scripting...myself included. This script is a perfect example of why they're so damned useful.<br><br><SMALL>--<br><A HREF="http://atuwiki.yock.name/wiki">Wiki Wiki</A><BR>The more secretive a government is, the more skeptical we need to be. --Shepard Smith</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16275735</guid>
<pubDate>Sat, 10 Jun 2006 09:42:52 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16260081</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> : Why not:<br><div class="code"><PRE><span class="codetext">if cal $mon $year | grep -qw $day<br>then<br>    echo "do stuff here if it's a valid date"<br>else<br>    echo "invalid date entered"<br>fi</SPAN></PRE></DIV>No need for the variable set when you can check for the result directly in the "if"<br><br>Steve <SMALL>&mdash; who nevertheless would have not thought to do it this clever way</SMALL><br><br><SMALL>--<br>Stephen J. Friedl &#149; Unix Wizard &#149; Microsoft Security MVP &#149; Tustin, California USA &#149; <A HREF="http://www.unixwiz.net">my web site</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16260081</guid>
<pubDate>Wed, 07 Jun 2006 23:30:29 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16258020</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : Quick and easy way to check for a valid date with "cal", which is pretty ubiquitous.<br><br><div class="code"><PRE><span class="codetext">is_valid=0<br>cal $mon $year | grep -qw $day &amp;&amp; is_valid=1<br>if &#91; $is_valid == 1 &#93;; then<br>    echo "do stuff here if it's a valid date"<br>else<br>    echo "invalid date entered"<br>fi</SPAN></PRE></DIV><br><SMALL>--<br>"Talk is cheap because the supply is greater than the demand" - Shelby Friedman</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16258020</guid>
<pubDate>Wed, 07 Jun 2006 18:58:17 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16235457</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> : I thought it was -f that did it, while -x just shows a more complete list of processes?<br><SMALL>--<br>UbuntuForums Administrator: <A HREF="http://ubuntuforums.org">try Ubuntu Linux</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16235457</guid>
<pubDate>Sun, 04 Jun 2006 16:26:45 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16234500</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> : Wow, just tripped across something in Linux by accident: the <B>x</B> option to the <B>ps</B> command. Running <B>ps -afx</B>, it shows all processes with their parent/child relationship - very handy.<br><div class="code"><PRE><span class="codetext"># ps afx<br>  PID TTY      STAT   TIME COMMAND<br>    1 ?        S      0:45 init &#91;3&#93;<br>    2 ?        SW     0:00 &#91;kflushd&#93;<br>    3 ?        SW     0:06 &#91;kupdate&#93;<br>    4 ?        SW     0:00 &#91;kpiod&#93;<br>    5 ?        SW     0:01 &#91;kswapd&#93;<br>    6 ?        SW&lt;    0:00 &#91;mdrecoveryd&#93;<br>  274 ?        S    267:19 named -t /chroot/named -u named -c /etc/named.conf<br>  327 ?        S    140:15 syslogd -m 0<br>  338 ?        S      0:00 klogd<br>  354 ?        S      0:00 /usr/sbin/atd<br>  370 ?        S      0:00 crond<br>  447 ?        S      0:56 /usr/libexec/postfix/master<br>  454 ?        S      0:17  \_ qmgr -l -t fifo -u<br> 9737 ?        S      0:00  \_ pickup -l -t fifo -u<br>  456 ?        S      8:00 /usr/local/sbin/sshd<br> 9754 ?        S      0:00  \_ sshd: root@pts/0   <br> 9756 pts/0    S      0:00      \_ -bash<br> 9770 pts/0    R      0:00          \_ ps afx<br>  491 tty1     S      0:00 /sbin/mingetty tty1<br>  492 tty2     S      0:00 /sbin/mingetty tty2</SPAN></PRE></DIV>Looking back in older versions, it's obviously been around a long time, but today was the first I'd ever seen it.<br><br>Nice!<br><br><SMALL>--<br>Stephen J. Friedl &#149; Unix Wizard &#149; Microsoft Security MVP &#149; Tustin, California USA &#149; <A HREF="http://www.unixwiz.net">my web site</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16234500</guid>
<pubDate>Sun, 04 Jun 2006 13:56:00 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16198172</link>
<description><![CDATA[<A HREF="/useremail/u/285748"><b>gatessux</b></A> : <div class="bquote"><SMALL>said by  fritzmp <A HREF="/useremail/u/463978"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>  :</SMALL><BR><BR>File Permissions: Some no0bs don't understand the number system that is associated with files and directories.<br><br>Read is worth a 4, Write is a 2, and execute is 1. Add them up for 7. <B>chmod 700 file_or_directory</B> is a owner rwx/7 group 0 and others/world 0<br><br>grid<br><br>******owner group world<br><br>read=4--X-----X-----X<br><br>write=2-X-------------<br><br>exec=1-X-----X-----X<br><br>Thus the above=755<br> </DIV>Sorry, I should of read all the replies before posting this... <br>Good one, I just wanted to furthur help out...<br>It's binary, as stated above, you need to do it 3 times for each, User of the file, Group that has rights, and Others (everyone else).<br><br>Here's a cheat table...<br>------------<br>RWX<br>000 = 0, no rights<br>001 = 1, eXecute<br>010 = 2, Write<br>011 = 3, Write/eXecute<br>100 = 4, Read<br>101 = 5, Read/eXecute<br>110 = 6, Read/Write<br>111 = 7, Read/Write/eXecute<br><br>(if it's 0 it's false, if it's 1, it's true)<br><br>Also:<br>chown = change owner, chgrp = change group<br>A great reference can be found here as well :<br>&raquo;<A HREF="http://www.tldp.org/LDP/intro-linux/html/sect_03_04.html" >www.tldp.org/LDP/intro-linux/htm&middot;&middot;&middot;_04.html</A><br><br>Thanks...]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16198172</guid>
<pubDate>Tue, 30 May 2006 05:45:42 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,16166643</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> : <div class="bquote"><SMALL>said by  Steve <A HREF="/useremail/u/340145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> :</SMALL><BR><BR>Symbolic permissions with chmod are a list of "sets", each of which is<br><br>scope<br>operation<br>permissions...</DIV>I take back everything I said about this.  Your little guide there came in very handy today.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16166643</guid>
<pubDate>Wed, 24 May 2006 23:33:59 EDT</pubDate>
</item>

<item>
<title>Painless Package Updates for SuSE</title>
<link>http://www.dslreports.com/forum/remark,16098933</link>
<description><![CDATA[<A HREF="/useremail/u/652505"><b>Happyrat</b></A> : Using YaST and a few custom repositories it's possible to easily update all of your applications in SuSE Linux (Any Version)...<br><br>Follow the instructions listed here on the SuSEwiki<br><br>&raquo;<A HREF="http://susewiki.org/index.php?title=Updating_KDE_and_other_applications_via_YaST" >susewiki.org/index.php?title=Upd&middot;&middot;&middot;via_YaST</A><br><br>And here's a couple of Listings of Repositories to make your life a little easier in this process...<br><br>&raquo;<A HREF="http://susewiki.org/index.php?title=Finding_RPMs" >susewiki.org/index.php?title=Finding_RPMs</A><br><br>&raquo;<A HREF="http://en.opensuse.org/Additional_YaST_Package_Repositories" >en.opensuse.org/Additional_YaST_&middot;&middot;&middot;sitories</A><br><br>&raquo;<A HREF="http://www.novell.com/products/suselinux/downloads/ftp/int_mirrors.html" >www.novell.com/products/suselinu&middot;&middot;&middot;ors.html</A><br><br>Choosing the right mirrors and directories will depend on which version of SuSE you are running...<br><SMALL>--<br>Crime wouldn't pay if the Government ran it...&raquo;<A HREF="http://www.fuzzyrat.com" >www.fuzzyrat.com</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,16098933</guid>
<pubDate>Mon, 15 May 2006 06:18:09 EDT</pubDate>
</item>

<item>
<title>Making make leave you alone in FreeBSD</title>
<link>http://www.dslreports.com/forum/remark,15563497</link>
<description><![CDATA[<A HREF="/useremail/u/1001074"><b>toadlife</b></A> : If you run FreeBSD as your desktop, and you frequently run portupgrade or portmanager to update your ports, you may have started an update of your ports and gone to bed while it compiles only to find in the morning that it stopped somewhere in the middle of compiling to ask you a configuration question about one of the programs.<br><br>To keep make from asking you any questions, put the following line in /etc/make.conf<br><div class="code"><PRE><span class="codetext">BATCH=YES</SPAN></PRE></DIV><br>With batch mode enabled, make will use the default options when compiling ports.<br><br>If you don't want batch mode to be turned on by default, you can pass the option to portupgrade when you run it.<br><br>With portupgrade, the option...<br><div class="code"><PRE><span class="codetext">-m BATCH=YES</SPAN></PRE></DIV>...will cause portupgrade to pass the batch=yes to the make command each time it compiles.<br><br>With portmanager, you cannot (AFAIK) pass arguments to make, so you would have to have the argument in make.conf<br><br>To pass the batch argument when compiling a single port (useful with huge meta-ports like kde), you can pass the batch argument like so...<br><br><div class="code"><PRE><span class="codetext">make BATCH=yes install clean</SPAN></PRE></DIV>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,15563497</guid>
<pubDate>Sun, 26 Feb 2006 02:45:48 EDT</pubDate>
</item>

<item>
<title>Re: remove CTRL-M characters from a file in UNIX</title>
<link>http://www.dslreports.com/forum/remark,15447011</link>
<description><![CDATA[<A HREF="/useremail/u/1188311"><b>tallisinn</b></A> : I believe that the command dos2unix will convert that. If it is available in your flavor of Linux.  ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,15447011</guid>
<pubDate>Fri, 10 Feb 2006 14:29:03 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,15393844</link>
<description><![CDATA[<A HREF="/useremail/u/1095658"><b>packetscan</b></A> : <div class="bquote"><SMALL>said by  Steve <A HREF="/useremail/u/340145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> :</SMALL><br><br> <BLOCKQUOTE><SMALL>said by somebody quoted by  paul1238 <A HREF="/useremail/u/233421"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> Some no0bs don't understand the number system that is associated with files and directories.<HR></BLOCKQUOTE>Neither the n00bs nor anybody else should fool with the numbers: it's difficult and often dangerous. Much better is to use the symbolic permissions, which are much less subject to surprises.<br><br>Symbolic permissions with chmod are a list of "sets", each of which is<br><br>scope<br>operation<br>permissions<br><br>"scope" is one or more of:<UL>&#8226;<B>u</B> = user (the owner of the file)&#8226;<B>g</B> = group&#8226;<B>o</B> = other&#8226;<B>a</B> = same as <B>ugo</B></UL><br><br>"operation" is one of<UL>&#8226;<B>+</B> add the permissions to existing ones&#8226;<B>-</B> subtract the permissions to existing ones&#8226;<B>=</B> set the permissions absolutely</UL><br><br>"permissions" is one or more or<UL>&#8226;<B>r</B> read permissions&#8226;<B>w</B> write permissions&#8226;<B>x</B> execute permissions</UL>(yes, there are other permissions, such as sticky bit and setuid, but that's all in the man pages).<br><br>By stringing these together you can do what you want:<br><br><B><TT>chmod a+r *</TT></B> - make all files readable<br><br>Because these permissions are <B>relative</B>, they don't destroy existing permission bits that you don't care about. There is no single numeric mode that would do this because no matter what you pick, it's going to muck with the (for instance) execute bits that you don't really want to. This means that you'll end up with directories that you can't get to any more.<br><br>Even when you <I>do</I> want to set hardcode permissions, do it with the symbolic mods:<br><br><B><TT>chmod a=rwx *</TT></B> - same as chmod 777<br><B><TT>chmod og= * </TT></B> - take away *everything* from others and group, but not touching "user" permissions<br><br>I cannot think of a downsize of the symbolic permissions, but I sure as hell can with the numbers.<br><br>Steve<br> </DIV>I've always liked the Number system<br>chmod ### filename<br>chmod ### foldername<br><br>0 = - - - <br>1 = - - x<br>2 = - w -<br>3 = - w x<br>4 = r w x<br>5 = r - x<br>6 = r w -<br>7 = r w x<br><SMALL>--<br>Who do you want to pay off today?</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,15393844</guid>
<pubDate>Fri, 03 Feb 2006 12:20:30 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,14312723</link>
<description><![CDATA[<A HREF="/useremail/u/465004"><b>ironwalker</b></A> : <div class="bquote"><SMALL>said by  wizard_ct <A HREF="/useremail/u/650893"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> :</SMALL><br><br>Building on the split tip earlier, I'm sure the benefits of tarring to small chunks is obvious - burning to dvds, copying to a FAT partition (2gb limit) - what have you. Here's how to do it:<br><br>tar -cvf - /home/dirToBackup | split -b 1000m - backup-09-06-2005<br><br>Allows you to tar a directory to chunks in place, without needing to create the massive one first. This saves a ton of space. <br><br>Of course customize tar params and and split size to taste. <br><br>Use cat to recover on the other end. <br><br>cat backup-09-06-2005a? > backup.tar<br><br>You could easily do this in place as well if you needed. <br> </DIV>Can I do it the same for Zip.I need to send a 48mb zip file to a windows user.I need them to be able to click first zip and open....if possible.<br>I will read man zip too.<br><br>Thanks for the tip though:)<br><br>Nevermind,I found it.<br>the tar command above made one 46mb archive for me and I had to use the split command seperately.<br><br>thanx again<br><SMALL>--<br>"LIVE FREE OR DIE"<br>...<br>&raquo;<A HREF="http://www.rif.org/" >www.rif.org/</A><br>...<br><A HREF="http://www.dslreports.com/forum/ftth">Fiber Optics</A> is the future of high-speed internet access. Stop by the <A HREF="http://www.dslreports.com/forum/ftth">BBR Fiber Optic</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,14312723</guid>
<pubDate>Wed, 07 Sep 2005 15:09:14 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,14307016</link>
<description><![CDATA[<A HREF="/useremail/u/650893"><b>wizard_ct</b></A> : Building on the split tip earlier, I'm sure the benefits of tarring to small chunks is obvious - burning to dvds, copying to a FAT partition (2gb limit) - what have you. Here's how to do it:<br><br>tar -cvf - /home/dirToBackup | split -b 1000m - backup-09-06-2005<br><br>Allows you to tar a directory to chunks in place, without needing to create the massive one first. This saves a ton of space. <br><br>Of course customize tar params and and split size to taste. <br><br>Use cat to recover on the other end. <br><br>cat backup-09-06-2005a? > backup.tar<br><br>You could easily do this in place as well if you needed. ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,14307016</guid>
<pubDate>Tue, 06 Sep 2005 19:38:23 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,14198471</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Multitasking on the command line is something I actually didn't know about until recently. I admit I felt stupid for not learning how to do this earlier, but I don't recall any intros to the command line that went over this.<br><br>If you are logged into the command line and don't have vt's enabled or don't want to switch vt's for whatever reason, you can still run a command and then run another while the previous job is running.<br><br>Let's say I <I>bunzip2 LDPHowtos.tar.bz2</I><br>That will take a while, and I want to read Slashdot, so I hit Ctrl-Z to pause the unzip and send me back to the shell.<br>Now I can type <I>bg</I> to resume the unzip in the background, and use elinks to check the news.<br><br>If you know the command you're about to run will take a while, then a better way to do that is to put a "&" at the end of the command. That will background the job and put you back at the shell also.<br><br>Let's say I want to run multiple commands at the same time in one line. I can do that by putting a "&" at the end of each separate job. Like this:<br> <I>bzip2 foo & bzip2 bar & bunzip2 wtf.bz2</I><br>then I do the Ctrl-Z and <I>bg</I> bit to put it in the background. <br>Or I could have just put another "&" at the end of the whole thing to background it.<br><br>Hope this helps someone new to the command line. I wish I knew this earlier. Would have saved me from having to wait for apps to finish whatever they were doing before I could check /.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,14198471</guid>
<pubDate>Tue, 23 Aug 2005 04:15:06 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13710523</link>
<description><![CDATA[<A HREF="/useremail/u/739334"><b>tld</b></A> : <div class="bquote"><SMALL>said by  steve1515 <A HREF="/useremail/u/182144"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><BR><BR>Ya, it only resolves each found IP once since each key in the hash is unique.<br><br>I'm also thinking that there is a simpler way than using dig...Maybe some built in perl resolving function, but I don't know what it is.<br> </DIV>I've always used this:<br><br><div class="code"><PRE><span class="codetext">sub iptoname {<br>        my ($ip) = @_;<br>        my (@list, $packed, @info, $hostname);<br>        @list = split(/\./,$ip);<br>        $packad = pack("C4",@list);<br>        if (@info = gethostbyaddr($packad,2)) {<br>                $hostname = $info&#91;0&#93;;<br>        } else {<br>                $hostname = "";<br>        }<br>        $hostname;<br>}</SPAN></PRE></DIV><br>I'm not sure I'd call it 'simpler' :D but it's probably a pretty efficient way of doing it.<br><br>Tom<br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13710523</guid>
<pubDate>Tue, 21 Jun 2005 12:36:18 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13584840</link>
<description><![CDATA[<A HREF="/useremail/u/182144"><b>steve1515</b></A> : Ya, it only resolves each found IP once since each key in the hash is unique.<br><br>I'm also thinking that there is a simpler way than using dig...Maybe some built in perl resolving function, but I don't know what it is.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13584840</guid>
<pubDate>Sun, 05 Jun 2005 19:40:36 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13584814</link>
<description><![CDATA[<A HREF="/useremail/u/950680"><b>canadiancree</b></A> : a good idea. one question though, wouldnt it be a bit taxing to resolve the DNS names everytime? What about adding a routine to have it look up a table or something to see if that IP range is already resolved, and if not, to then seek it out?<br><br>Unless you already have that, my perl is rustier than a '72 Vega]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13584814</guid>
<pubDate>Sun, 05 Jun 2005 19:37:24 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13584529</link>
<description><![CDATA[<A HREF="/useremail/u/182144"><b>steve1515</b></A> : Here's a perl script I wrote that looks at apache logs and prints out unique counts, IPs, and DNS names.<br><br><SMALL>syntax colored perl code</SMALL>:<div class="syntax"><PRE><span class="codetext"><font color="#FFFFFF"><font color="#ff40ff">#!/usr/bin/perl -w</font><br> <br><font color="#ffff00">use strict</font>;<br> <br><font color="#ffff00">my</font> <font color="#00ffff">$log_file</font> = <font color="#ffff00">'</font><font color="#ff6060">/var/log/apache/access_log</font><font color="#ffff00">'</font>;<br> <br><font color="#ffff00">my</font> <font color="#00ffff">%IP_count</font>;  <font color="#8080ff">#*** Hash containing count of hits from each IP</font><br><font color="#ffff00">my</font> <font color="#00ffff">%IP_DNS</font>;  <font color="#8080ff">#*** Hash containing the reverse lookups of IPs</font><br><font color="#ffff00">my</font> <font color="#00ffff">@sorted_IPs</font>;  <font color="#8080ff">#*** List of IPs sorted by count</font><br> <br><font color="#8080ff">#*** Check if log file exists and then try to open it</font><br><font color="#ffff00">-e</font> <font color="#00ffff">$log_file</font> <font color="#ffff00">or</font> <font color="#ffff00">die</font> <font color="#ffff00">&quot;</font><font color="#ff6060">ERROR: File not found.</font><font color="#ff40ff">\n</font><font color="#ffff00">&quot;</font>;<br><font color="#ffff00">open</font> <font color="#00ffff">LOG</font>, <font color="#ffff00">&quot;</font><font color="#ff6060">&lt; </font><font color="#00ffff">$log_file</font><font color="#ffff00">&quot;</font> <font color="#ffff00">or</font> <font color="#ffff00">die</font> <font color="#ffff00">&quot;</font><font color="#ff6060">ERROR: Can't create file: </font><font color="#00ffff">$!</font><font color="#ffff00">&quot;</font>;<br> <br><font color="#8080ff">#*** Go through log and put IPs and counts in the hash</font><br><font color="#ffff00">while</font> (<font color="#00ffff">&lt;LOG&gt;</font>)<br>{<br>  <font color="#00ffff">$IP_count{$&amp;}</font>++ <font color="#ffff00">if</font> (<font color="#ffff00">/</font><font color="#ff6060">^</font><font color="#ff40ff">\d</font><font color="#ff40ff">+</font><font color="#ff40ff">\.\d</font><font color="#ff40ff">+</font><font color="#ff40ff">\.\d</font><font color="#ff40ff">+</font><font color="#ff40ff">\.\d</font><font color="#ff40ff">+</font><font color="#ffff00">/</font>);<br>}<br> <br><font color="#ffff00">close</font> <font color="#00ffff">LOG</font>;<br> <br><font color="#8080ff">#*** Go through each IP found, resolve it, and store result in the hash</font><br><font color="#ffff00">foreach</font> <font color="#ffff00">my</font> <font color="#00ffff">$IP</font> (<font color="#ffff00">keys</font> <font color="#00ffff">%IP_count</font>)<br>{<br>  <font color="#ffff00">chomp</font>(<font color="#00ffff">$IP_DNS{$IP}</font> = <font color="#ffff00">`</font><font color="#ff6060">dig +short -x </font><font color="#00ffff">$IP</font><font color="#ffff00">`</font>);<br>}<br> <br><font color="#8080ff">#*** Store list of sorted IPs by count</font><br><font color="#00ffff">@sorted_IPs</font> = <font color="#ffff00">sort</font> {<font color="#00ffff">$IP_count{$a}</font> &lt;=&gt; <font color="#00ffff">$IP_count{$b}</font> <font color="#ffff00">or</font><br>                    <font color="#00ffff">$IP_DNS{$a}</font> <font color="#ffff00">cmp</font> <font color="#00ffff">$IP_DNS{$b}</font> <font color="#ffff00">or</font><br>                    <font color="#00ffff">$a</font> <font color="#ffff00">cmp</font> <font color="#00ffff">$b</font>} <font color="#ffff00">keys</font> <font color="#00ffff">%IP_count</font>;<br> <br><font color="#8080ff">#*** Print out counts, IP, and DNS names</font><br><font color="#ffff00">foreach</font> <font color="#ffff00">my</font> <font color="#00ffff">$IP</font> (<font color="#00ffff">@sorted_IPs</font>)<br>{<br>  <font color="#ffff00">print</font> <font color="#ffff00">&quot;</font><font color="#ff6060">   </font><font color="#00ffff">$IP_count{$IP}</font><font color="#ff40ff">\t</font><font color="#00ffff">$IP</font><font color="#ff40ff">\t</font><font color="#00ffff">$IP_DNS{$IP}</font><font color="#ff40ff">\n</font><font color="#ffff00">&quot;</font>;<br>}<br></font></SPAN></PRE></DIV><br>This is my first perl program, so if theres some crazy error please let me know. :)<br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13584529</guid>
<pubDate>Sun, 05 Jun 2005 18:59:04 EDT</pubDate>
</item>

<item>
<title>Re: Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13557157</link>
<description><![CDATA[<A HREF="/useremail/u/782124"><b>BeesTea</b></A> : <div class="bquote"><SMALL>said by  deblin <A HREF="/useremail/u/465839"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><br><br>Ok, we're getting a bit carried away now :)<br><br> </DIV>With the "Yep, one up"?  I agree.<br><SMALL>--<br>$ /bin/whoami <BR>nobody</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13557157</guid>
<pubDate>Thu, 02 Jun 2005 09:28:10 EDT</pubDate>
</item>

<item>
<title>Re: Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13555694</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : Yep, and just in case you actually need to type EOF in your message:<br><br><div class="code"><PRE><span class="codetext">cat - | mail -s subj user@host.com<br>type<br>your stuff<br>here<br>with an<br>EOF if you want<br>^D</SPAN></PRE></DIV><br>Where ^D is a ctrl-d. Ok, we're getting a bit carried away now :)<br><br><SMALL>--<br>$(perl -e 'print pack("H*","6d616e207065726c0a")')</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13555694</guid>
<pubDate>Thu, 02 Jun 2005 01:08:27 EDT</pubDate>
</item>

<item>
<title>Re: Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13555178</link>
<description><![CDATA[<A HREF="/useremail/u/782124"><b>BeesTea</b></A> : For a long one-shot message, you can use cat<br><br><div class="code"><PRE><span class="codetext">$ cat - | mail -s Subject address@domain.com &lt;&lt; EOF<br>&gt; This is another way to send mail<br>&gt;<br>&gt; Even<br>&gt; with<br>&gt; returns!<br>&gt;<br>&gt;<br>&gt; EOF<br>$</SPAN></PRE></DIV><br><SMALL>--<br>$ /bin/whoami <BR>nobody</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13555178</guid>
<pubDate>Wed, 01 Jun 2005 23:53:28 EDT</pubDate>
</item>

<item>
<title>Re: Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13554414</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : Yep, that works. But if your message is long or pre-composed, I'm sure you won't want to type it out again. :) But yes, that's perfect for a quick message.<br><SMALL>--<br>$(perl -e 'print pack("H*","6d616e207065726c0a")')</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13554414</guid>
<pubDate>Wed, 01 Jun 2005 22:24:34 EDT</pubDate>
</item>

<item>
<title>Re: Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13554378</link>
<description><![CDATA[<A HREF="/useremail/u/864682"><b>ghost16825</b></A> : How about:<br><br>(without file creation)<br><br><div class="code"><PRE><span class="codetext">echo "message here enclosed in double quotes" | mail -s Subject address@domain.com</SPAN></PRE></DIV>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13554378</guid>
<pubDate>Wed, 01 Jun 2005 22:20:53 EDT</pubDate>
</item>

<item>
<title>Re: Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13554026</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : <div class="bquote"><SMALL>said by  ghost16825 <A HREF="/useremail/u/864682"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><br><br>Of course this requires your message to be in message.txt. I'm sure someone can find a method without having to invoke cat at all.</DIV>mail -s subject emailaddress@domain.com &lt; message.txt<br><br>;)<br><SMALL>--<br>$(perl -e 'print pack("H*","6d616e207065726c0a")')</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13554026</guid>
<pubDate>Wed, 01 Jun 2005 21:48:35 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13546982</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> : <div class="code"><PRE><span class="codetext">dd if=/dev/urandom of=- bs=1M count=10| mail emailaddress@domain.com</SPAN></PRE></DIV>e-mail 10MB of randomness? ;)<br><br><SMALL>--<br>Official Ubuntu Linux Forum Super Moderator: <A HREF="http://ubuntuforums.org">try Ubuntu Linux</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13546982</guid>
<pubDate>Wed, 01 Jun 2005 06:45:06 EDT</pubDate>
</item>

<item>
<title>Quick mail sending</title>
<link>http://www.dslreports.com/forum/remark,13544124</link>
<description><![CDATA[<A HREF="/useremail/u/864682"><b>ghost16825</b></A> : This probably not original, but at the moment I quite like this neat one liner:<br><br>(Useful when you don't care about the subject title and just want to send it off)<br><br><div class="code"><PRE><span class="codetext">cat message.txt | mail emailaddress@domain.com</SPAN></PRE></DIV><br>or if you want a subject<br><br><div class="code"><PRE><span class="codetext">cat message.txt | mail -s Subject address@domain.com</SPAN></PRE></DIV><br>Of course this requires your message to be in message.txt. I'm sure someone can find a method without having to invoke cat at all.<br><br><SMALL>--<br>Admin of the Kerio 2x-like open source project:<BR><A HREF="http://sourceforge.net/projects/kerio/">http://sourceforge.net/projects/kerio/</A><BR><A HREF="http://kerio.sourceforge.net/">http://kerio.sourceforge.net/</A><BR></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13544124</guid>
<pubDate>Tue, 31 May 2005 21:11:53 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13541180</link>
<description><![CDATA[<A HREF="/useremail/u/246096"><b>yock</b></A> : Assuming you add your user to the slocate group. Without being a member of that group it should follow file permissions.<br><SMALL>--<br>This signiture pisses you off.</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13541180</guid>
<pubDate>Tue, 31 May 2005 15:15:47 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13484789</link>
<description><![CDATA[<A HREF="/useremail/u/878241"><b>JohnInSJ</b></A> : <div class="bquote"><SMALL>said by  jdong <A HREF="/useremail/u/655964"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><BR><BR>oh, so slocate is sgid/suid?<br> </DIV><div class="code"><PRE><span class="codetext">$ ls -ld `which slocate`<br>-rwxr-sr-x  1 root slocate 26388 Apr 16  2004 /usr/bin/slocate</SPAN></PRE></DIV>Looks like it [FC2]<br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13484789</guid>
<pubDate>Tue, 24 May 2005 16:42:12 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13484748</link>
<description><![CDATA[<A HREF="/useremail/u/782124"><b>BeesTea</b></A> : Generally<br><br>$ ls -l `which slocate`<br>-rwx--s--x  1 root slocate 32468 Nov 12  2004 /usr/bin/slocate<br><SMALL>--<br>$ /bin/whoami <BR>nobody</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13484748</guid>
<pubDate>Tue, 24 May 2005 16:37:31 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13484665</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> : oh, so slocate is sgid/suid?]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13484665</guid>
<pubDate>Tue, 24 May 2005 16:28:15 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13475799</link>
<description><![CDATA[<A HREF="/useremail/u/782124"><b>BeesTea</b></A> : <div class="bquote"><SMALL>said by  jdong <A HREF="/useremail/u/655964"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><br><br>slocate started doing that, but nothing stops an experienced user from directly parsing the locate database,<br> </DIV>Well, except for file permissions that is.<br><br>$ ls -ld /var/lib/slocate/<br>drwxr-x---  2 root slocate 104 May 23 03:22 /var/lib/slocate/<br><SMALL>--<br>$ /bin/whoami <BR>nobody</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13475799</guid>
<pubDate>Mon, 23 May 2005 15:38:54 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13475734</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> : slocate started doing that, but nothing stops an experienced user from directly parsing the locate database, or using something like fakeroot to convince locate to let him through (though the latter can be foiled by checking FS permissions)<br><SMALL>--<br>Official Ubuntu Linux Forum Super Moderator: <A HREF="http://ubuntuforums.org">try Ubuntu Linux</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13475734</guid>
<pubDate>Mon, 23 May 2005 15:28:40 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13473904</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : Ah interesting, I guess I should have assumed the developers were smarter than that, but I never bothered to actually test it. ;)<br><SMALL>--<br>$(perl -e 'print pack("H*","6d616e207065726c0a")')</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13473904</guid>
<pubDate>Mon, 23 May 2005 11:07:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13473333</link>
<description><![CDATA[<A HREF="/useremail/u/878241"><b>JohnInSJ</b></A> : <div class="bquote"><SMALL>said by  deblin <A HREF="/useremail/u/465839"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><BR><BR>It's faster because it's reading the locate database. locate's database is built WITH find, typically once a day in a cron job. So yes, it's faster, but it's often out of date. I disable locate on my box, since it would theoretically give someone knowledge of the existence of files that non-privileged users shouldn't know exist.<br> </DIV>Fyi, it seems to filter results based on user permission:<br><div class="code"><PRE><span class="codetext">$ locate accounting<br> <br>$ su -<br># # locate accounting<br>/root/accounting<br>#</SPAN></PRE></DIV>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13473333</guid>
<pubDate>Mon, 23 May 2005 09:36:21 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13472262</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : <div class="bquote"><SMALL>said by Sexy Bern:</SMALL><br><br>"locate -i" does the "find ... | grep" *much* better<br> </DIV>It's faster because it's reading the locate database. locate's database is built WITH find, typically once a day in a cron job. So yes, it's faster, but it's often out of date. I disable locate on my box, since it would theoretically give someone knowledge of the existence of files that non-privileged users shouldn't know exist.<br><SMALL>--<br>$(perl -e 'print pack("H*","6d616e207065726c0a")')</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13472262</guid>
<pubDate>Mon, 23 May 2005 02:19:55 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13469141</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : "locate -i" does the "find ... | grep" *much* better]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13469141</guid>
<pubDate>Sun, 22 May 2005 17:43:21 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13331088</link>
<description><![CDATA[<A HREF="/useremail/u/1198969"><b>welldog</b></A> : I find this perl one liner to be invaluable :<br><br><div class="code"><PRE><span class="codetext">cat /var/log/httpd/logs/access-log | perl -ne 'print $&amp; . "\n" if /(\d+)\.(\d+)\.(\d+)\.(\<br> *d+)/'| sort | uniq -c | sort -n<br><br>(*) WARNING 1 long line(s) split</SPAN></PRE></DIV>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13331088</guid>
<pubDate>Wed, 04 May 2005 19:04:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,13024361</link>
<description><![CDATA[<A HREF="/useremail/u/585203"><b>Chillybott</b></A> : after removing my hand-built router in favor of a SOHO last week, I have a minor tip for those of us who use internal DNS<br><br>My router allows reserved IP addresses assigned via DHCP, and using that capability, I configured BIND on my home server, and I was getting reverse lookups that were just peachy, as well as forward lookups that were fine as long as I used my "my-network.net" suffix, but it would not work without the suffix specified:<br><br>for example:<br><br><div class="bquote">$ host 192.168.1.100<br>100.1.168.192.in-addr.arpa domain name pointer ns.my-network.net<br>$ host namesrv.my-network.net<br>namesrv.my-network.net has address 192.168.1.100<br>$ host ns<br>Host namesrv. not found: 3(NXDOMAIN)<br></DIV>what I hadn't realized is that the router's "Domain name/Workgroup specification" value needs to be set up to point to my desired DNS-suffix...I ignored it because I was running named on my linux server, not on my router.<br><br>Filling in my internal domain name for that router value worked like a charm, now when I lookup just the DNS assigned name, without specifying the internal domain suffix, it's as smooth as melted butter :)<br><br>fwiw:<br>DNS server == FC3 running on an I686<br>SOHO Router == Netgear FVS318<br><br>*the names of the internal domain and IP address of internal machines have been changed to protect the not-so-innocent ;)<br><SMALL>--<br>Just because nobody complains doesn't mean all parachutes are perfect.</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,13024361</guid>
<pubDate>Mon, 28 Mar 2005 11:50:20 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12861164</link>
<description><![CDATA[<A HREF="/useremail/u/1170096"><b>JennyJ3</b></A> : Ever need to take an action on each line in a file, and want a simple, one liner way to do it? Try a loop in bash:<br><br>for x in `cat file` ; do command $x ; done<br><br>Simple and effective.<br><SMALL>--<br>www.TestMyPorts.com - Are your ports properly forwarded? Find out here!</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12861164</guid>
<pubDate>Tue, 08 Mar 2005 17:53:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12799205</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> : Shoot, I'd be curious if /etc/conf.d/fux0red is configured properly, and if /etc/init.d/fux0red should even be in rc to begin with.<br><SMALL>--<br>Updated My Journal</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12799205</guid>
<pubDate>Tue, 01 Mar 2005 07:05:04 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12798042</link>
<description><![CDATA[<A HREF="/useremail/u/684126"><b>shray</b></A> : /etc/init.d/fux0rd stop<br><br>Fixes simple problems in *nix systems!:o<br><br>Edit:<br>/etc/init.d/holyshit restart<br>Also another good init.d! :)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12798042</guid>
<pubDate>Tue, 01 Mar 2005 00:02:22 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12745943</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> :  df -h | grep hd<br><br>is a much simpler way of accomplishing the same task. -h choses units of KB, MB, or GB (maybe TB? Don't have anything that big), whichever is more appropriate.<br><SMALL>--<br>Official Ubuntu Linux Forum Super Moderator: <A HREF="http://ubuntuforums.org">try Ubuntu Linux</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12745943</guid>
<pubDate>Wed, 23 Feb 2005 06:45:47 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12744426</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Just came up with this one which I quite like.<br><br>df|awk '/dev\/hd/{sum+=$4} END{print sum/1024/1024"Gb Free Space"}'<br><br>Shows the free space on hard disks (assuming your CD drive is /dev/hd*)<br><br>Aimaz]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12744426</guid>
<pubDate>Tue, 22 Feb 2005 23:39:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12561362</link>
<description><![CDATA[<A HREF="/useremail/u/830143"><b>mlmurray</b></A> :  <div class="bquote"><SMALL>said by UseLinux:</SMALL><BR><BR>Here's my little tip... not exactly "spectacular" in nature, but I find it's something I use fairly frequently since the machine I run Debian on has a fairly small HD (20 GB).<br><br>To find out how much free disk space you have remaining (as well as how much you have used) on all your hard drive partitions in <I>megabytes</I>, type the following command:<br><br><STRONG>df -BM | grep /dev/hd</STRONG><br><br>If you wish to view this information in gigabytes, simply change the -BM option to -BG.<br> </DIV>A slight variation of this is `df -h`.  The -h is for "human readable", I think.  It tries to choose the most relevent measure to use, so it can give a combination of megabytes, gigabytes, or even kilobites.<br><br>The -h switch also works on `ls` too as in `ls -lh`.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12561362</guid>
<pubDate>Wed, 02 Feb 2005 14:43:23 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12424327</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Here's my little tip... not exactly "spectacular" in nature, but I find it's something I use fairly frequently since the machine I run Debian on has a fairly small HD (20 GB).<br><br>To find out how much free disk space you have remaining (as well as how much you have used) on all your hard drive partitions in <I>megabytes</I>, type the following command:<br><br><STRONG>df -BM | grep /dev/hd</STRONG><br><br>If you wish to view this information in gigabytes, simply change the -BM option to -BG.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12424327</guid>
<pubDate>Wed, 19 Jan 2005 02:56:29 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12400649</link>
<description><![CDATA[<A HREF="/useremail/u/308775"><b>c4delta</b></A> : Do you know a good resource that documents other terminal escape sequences?  Thanks.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12400649</guid>
<pubDate>Sun, 16 Jan 2005 15:49:46 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12003290</link>
<description><![CDATA[<A HREF="/useremail/u/914821"><b>clesters</b></A> : Use a wheel mouse in FreeBSD 5.3<br><br># cd /usr/ports/x11/imwheel<br># make install clean<br><br>Start imwheel on boot,<br><br>Edit your xorg.conf file<br># vi /etc/x11/xorg.conf<br><br>Under:<br>Section &#147;InputDevice&#148;<br>Identifier &#147;Mouse0&#8243;<br>add Option &#147;ZAxisMapping&#148; &#147;4 5&#8243;<br><br>Disable 3 button mouse emulation in xorg.conf<br>comment out any<br># Option &#147;Emulate3Buttons&#148;<br># Option &#147;Emulate3Timeout&#148; &#147;50&#8243;<br><br>Disable emulation in rc.conf<br>comment out<br>#mouse_flags="-3&#8243;<br><br>Now restart X and you should be good to go.<br><SMALL>--<br>bsdzone.net</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12003290</guid>
<pubDate>Wed, 01 Dec 2004 19:16:54 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,12003228</link>
<description><![CDATA[<A HREF="/useremail/u/914821"><b>clesters</b></A> : Copy a directory with tar.<br><br>This will copy all files and symlinks.<br>$ ( cd /to/directory/to/copy && tar cf - . ) | (cd /copy/to/directory && tar xBf -)<br><br>This will copy to a remote machine that is enabled with ssh.<br>$ ( cd /to/directory/to/copy && tar cf - . ) | ssh user@remote_machine &#147;(cd /directory/to/copy/to && tar xvpf - )&#148; <br><SMALL>--<br>bsdzone.net</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,12003228</guid>
<pubDate>Wed, 01 Dec 2004 19:09:06 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11995748</link>
<description><![CDATA[<A HREF="/useremail/u/177823"><b>kleeman</b></A> : If you are setting up a Debian based distro (Knoppix, Ubuntu, Libranet etc etc), this guide can be very useful:<br><br>&raquo;<A HREF="http://www.togaware.com/linux/survivor/" >www.togaware.com/linux/survivor/</A>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11995748</guid>
<pubDate>Tue, 30 Nov 2004 22:00:53 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11712735</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> : Gentoo/Portage users:<br><br>Making -* the first part of USE= in make.conf cuts down spinner time immensely on emerges, as well as cutting out unnecessary package installs. <br><br>Just make sure you include any necessary use flags before emerging. <br><br> <BLOCKQUOTE><SMALL>said by example from "/etc/make.conf":</SMALL><HR>USE="-* x86 3dnow X Xaw3d aalib alsa apache2 arts audiofile avi bindist bzlib caps cdr cross crypt dedicated dga dio divx4linux dvd encode exif ftp gd ggi gif gpm gstreamer imagemagick imlib jack java jikes joystick jpeg kde libwww mad memlimit mikmod mmx motif mozilla mpeg msn nas ncurses nocd offensive oggvorbis openal opengl oscar pam png posix prelude qt quicktime readline spell ssl svga szip tcpd tiff truetype usb videos wmf xine xinerama xmms xosd xv xvid yahoo zlib insecure-drivers"<HR></BLOCKQUOTE><br><SMALL>--<br>Updated My Journal<BR><A HREF="http://www.tweakersparadise.com">TP&C</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11712735</guid>
<pubDate>Thu, 28 Oct 2004 14:40:12 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11637962</link>
<description><![CDATA[<A HREF="/useremail/u/782124"><b>BeesTea</b></A> : A quick tip for packing up a Gentoo installation should you happen to forget to emerge your system using the -b (create a binary package as well as compile and install source) flag to emerge.<br><br><div class="code"><PRE><span class="codetext">emerge sync ; emerge -up world<br> <br>for i in `qpkg -I -nc`<br> do<br>  quickpkg $i<br>done<br> <br>tar -cvf ~/portage-`date +%y%m%d`.tar /usr/portage<br></SPAN></PRE></DIV><br>This will make a binary package of every package you've compiled and installed.  Using this instead of a tarfile from / allows you to reinstall any single package or even use them elsewhere on another system.<br><br>Cheers,<br>-BeesT<br><br><SMALL>--<br>echo 16i[q]sa[ln0=aln100%Pln100/snlbx]sbA0D4D465452snlb xq |dc</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11637962</guid>
<pubDate>Wed, 20 Oct 2004 09:41:35 EDT</pubDate>
</item>

<item>
<title>Re: remove CTRL-M characters from a file in UNIX</title>
<link>http://www.dslreports.com/forum/remark,11636823</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Thanks. That helped.<br>Small correction :<br>In vi, enter as - while keeping Ctrl pressed, press V, then M.<br>For removing ^M in a file, open a file in vi editor and then give following command<br><br>:%s/^M//g<br><br>(remember the above sequence to enter ^M character).]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11636823</guid>
<pubDate>Wed, 20 Oct 2004 03:20:47 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11459210</link>
<description><![CDATA[<A HREF="/useremail/u/811675"><b>cdru</b></A> :  <BLOCKQUOTE><SMALL>said by  theguy <A HREF="/useremail/u/883043"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>To see which programs are using the network connections<br><br>netstat -pan ( to test )<br> <HR></BLOCKQUOTE>I think you have an extra p in there.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11459210</guid>
<pubDate>Wed, 29 Sep 2004 15:41:08 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11417060</link>
<description><![CDATA[<A HREF="/useremail/u/883043"><b>theguy</b></A> : To see which programs are using the network connections<br><br>netstat -pan ( to test )]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11417060</guid>
<pubDate>Fri, 24 Sep 2004 12:47:40 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11293521</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> : shouldn't you use rm \\, since \; is an invalid escape sequence?<br><SMALL>--<br>WASTING TIME spelled backwards is... :)</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11293521</guid>
<pubDate>Fri, 10 Sep 2004 06:26:56 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11287952</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : If someone happens to create a filename named '\' do the following:<br><br>rm '\';<br><br>Instead of rm "\";<br><br>Works for me.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11287952</guid>
<pubDate>Thu, 09 Sep 2004 15:24:48 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11287787</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> : Try putting it in quotation marks, you should start a new thread for that, though.<br><SMALL>--<br>Updated My Journal<BR><A HREF="http://www.tweakersparadise.com">TP&C</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11287787</guid>
<pubDate>Thu, 09 Sep 2004 15:06:04 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11287432</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Need to delete a file with file name \ .Was ceated by mistake.<br>From man pages tried the command,<br>find . \( -name '\' \) -exec rm -f {} \;<br><br>Could not delete:(  <br>Any suggestions?]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11287432</guid>
<pubDate>Thu, 09 Sep 2004 14:23:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,11150820</link>
<description><![CDATA[<A HREF="/useremail/u/1064796"><b>Kurse0</b></A> :  <BLOCKQUOTE><SMALL>said by  jamies0320 <A HREF="/useremail/u/823242"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br>if you locate a file that is activly growing, you can use<br><br>fuser FILENAME<br><br>to find the process id of the user, and then<br><br>ps -ef|grep PROCESS_ID to determine who is using the file.<br> <HR></BLOCKQUOTE><br><br>or just fuser -u FILENAME]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,11150820</guid>
<pubDate>Wed, 25 Aug 2004 13:58:32 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10876930</link>
<description><![CDATA[<A HREF="/useremail/u/811675"><b>cdru</b></A> :  <BLOCKQUOTE><SMALL>said by  Steve <A HREF="/useremail/u/340145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>The oldest UNIX FAQ I know about: "How do I remove a file whose name begins with a dash" (because the filename gets confused with an option), and the answer is to prefix it with dot-slash<BLOCKQUOTE>code:<HR><PRE>$ <B>rm ./-troublesome-filename</B></PRE><HR></BLOCKQUOTE><br> <HR></BLOCKQUOTE>I was just going to post this and I thought I would double check to make sure it wasn't already in there.  <br><br>Many of the users on my company machines have the tendency to use the arrow keys and/or other escape codes to attempt to correct mistyped commands.  This usually results in very creative file names that are a pain to remove.  Often in these directories when an ls is performed the output gets garbled as the terminal emulator interprets those escape codes as a clear screen, carriage return, etc.<br><br>To get a list of files with non-printable characters octet values, do a "ls -lab".  Look for files with \### in them.  To easily remove them, just substitute a ? and or * for the file name.  I always recommend typing "ls -lab filename" first where filename is the wildcard representation of the file you are trying to get rid of.  This way you can make sure you are only getting rid of the one file and not several similar.  Or of course just use the \### octet value.<br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10876930</guid>
<pubDate>Mon, 26 Jul 2004 09:10:53 EDT</pubDate>
</item>

<item>
<title>Re: This is the best thread ever.</title>
<link>http://www.dslreports.com/forum/remark,10794124</link>
<description><![CDATA[<A HREF="/useremail/u/811675"><b>cdru</b></A> :  <BLOCKQUOTE><SMALL>said by  lanboyo <A HREF="/useremail/u/630606"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br>2.<br>to replace variable whitespace with a single space<br><br>sed s/\ \ */\ /g<br><br>...useful for ordering output into parsable text...<br><HR></BLOCKQUOTE>tr -s " " will do the same and is easy to remember.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10794124</guid>
<pubDate>Fri, 16 Jul 2004 14:28:20 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10793788</link>
<description><![CDATA[<A HREF="/useremail/u/1006726"><b>sundaram123</b></A> : Hi,<br><br>we can use this command to  find file modified 1 day or day older<br><br><div class="code"><PRE><span class="codetext">find / -mtime 1 -o -mtime +1 -type f -print<br></SPAN></PRE></DIV>To find all local desk file( updatedb command uses this find command) .<br><div class="code"><PRE><span class="codetext">/usr/bin/find / ( -fstype nfs -o -fstype NFS -o -fstype proc -o -fstype afs -o -fstype smb<br> *fs -o -fstype autofs -o -type d -regex \(^/tmp$\)\|\(^/usr/tmp$\)\|\(^/var/tmp$\)\|\(^/afs<br> *$\)\|\(^/var/spool$\) ) -prune <br><br>(*) WARNING 1 long line(s) split<br></SPAN></PRE></DIV>-SR<br><br><SMALL>--<br>SCSecA, SCNA, SCSA, SCWCD, SCJP</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10793788</guid>
<pubDate>Fri, 16 Jul 2004 13:49:11 EDT</pubDate>
</item>

<item>
<title>Re: remove CTRL-M characters from a file in UNIX</title>
<link>http://www.dslreports.com/forum/remark,10781745</link>
<description><![CDATA[<A HREF="/useremail/u/811675"><b>cdru</b></A> :  <BLOCKQUOTE><SMALL>said by  sundaram123 <A HREF="/useremail/u/1006726"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Linux you can use col command to remove CTRL+M character<br><br>col -b --<br>SCSecA, SCNA, SCSA, SCWCD, SCJP</SMALL><br> <HR></BLOCKQUOTE>For those who have a sed fetish, 'sed s/^M//g' will also get rid of the ^M.  The ^M is not the characters ^ and M, but the combined control code.  In vi, they can be entered with a Ctrl-V, then Enter.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10781745</guid>
<pubDate>Thu, 15 Jul 2004 09:29:03 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10776490</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> : On a  framebuffer in Linux, you can press SHIFT+PGUP or SHIFT+PGDOWN to scroll. Note that if you switch to another vt, the scroll buffer is cleared.<br><SMALL>--<br>WASTING TIME spelled backwards is... :)</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10776490</guid>
<pubDate>Wed, 14 Jul 2004 18:14:22 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10774219</link>
<description><![CDATA[<A HREF="/useremail/u/811675"><b>cdru</b></A> :  <BLOCKQUOTE><SMALL>said by  jamies0320 <A HREF="/useremail/u/823242"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>I seem to remember that on SCO the command "memsize" will display the amount of memory installed.  Does anyone know of a similar command on other flavors ?<HR></BLOCKQUOTE>hw in SCO OpenServer will tell you a variety of memory as well as other information.  It also will tell you an educated guess as to the processor speed/type.  Quite handy when you have over a dozen different models of computers out in the field.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10774219</guid>
<pubDate>Wed, 14 Jul 2004 14:17:01 EDT</pubDate>
</item>

<item>
<title>Re: remove CTRL-M characters from a file in UNIX</title>
<link>http://www.dslreports.com/forum/remark,10774101</link>
<description><![CDATA[<A HREF="/useremail/u/1006726"><b>sundaram123</b></A> : Linux you can use col command to remove CTRL+M character<br><br>col -b --<br>SCSecA, SCNA, SCSA, SCWCD, SCJP</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10774101</guid>
<pubDate>Wed, 14 Jul 2004 14:07:37 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10588617</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> :  <BLOCKQUOTE><SMALL>said by  jamies0320 <A HREF="/useremail/u/823242"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br>I seem to remember that on SCO the command "memsize" will display the amount of memory installed.  Does anyone know of a similar command on other flavors ?<br><br>I'm most interested in AIX or HP-UX.<br> <HR></BLOCKQUOTE><br><br>Doesn't the <B>free</B> command perform a similar function? (I know it's in BSD and Linux)<br><SMALL>--<br>WASTING TIME spelled backwards is... :)</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10588617</guid>
<pubDate>Wed, 23 Jun 2004 14:55:50 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10584359</link>
<description><![CDATA[<A HREF="/useremail/u/823242"><b>jamies0320</b></A> : You can use uptime to find out how long it has been since the last boot, but who -b will tell you the date and time of the last boot.<br><br>I seem to remember that on SCO the command "memsize" will display the amount of memory installed.  Does anyone know of a similar command on other flavors ?<br><br>I'm most interested in AIX or HP-UX.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10584359</guid>
<pubDate>Wed, 23 Jun 2004 00:48:50 EDT</pubDate>
</item>

<item>
<title>More ssh goodness - Turbo mode logins - Good Stuff</title>
<link>http://www.dslreports.com/forum/remark,10569302</link>
<description><![CDATA[<A HREF="/useremail/u/987024"><b>dtanner</b></A> : <PRE><br>Turbo mode logins using ssh keys.<br> <br>1) On local-machine type this command...<br>   <br><I><B>   $ ssh-keygen -t rsa</B></I><br> <br><U>TIP:</U> When it asks for a passphrase just hit enter.<br>     ie: Do not give it a passphrase.<br> <br>2) This will create a file ~/.ssh/id_rsa.pub<br> <br>3) This will be used for your *PUBLIC* key.<br> <br>4) On local-machine issue this command...<br><I><B><br>   $ scp ~/.ssh/id_rsa.pub user@remote-machine:.ssh/authorized_keys2<br></B></I><br>  Assuming you have the same username on both local-machine<br>  and remote-machine you do not have to use the<br>  user@remote-machine. Just remote-machine will do in the<br>  'scp' line above in this case. For the purpose of being<br>  "proper" this is the syntax I used above...<br>  user@remote-machine<br> <br><U><B>IMPORTANT NOTE:</B></U> NEVER EVER copy the file ~/.ssh/id_rsa to another machine.<br>ONLY ~/.ssh/id_rsa.pub ok?<br>You do not need to do this for any reason.<br>Don't do it.<br><I><B><U>You have been warned.</U></B></I><br> <br>5) On local-machine issue this command...<br><I><B><br>   $ ssh remote-machine<br></B></I><br>6) Badabing. Sweet.<br> <br>You want more automation ?<br>Check this out...<br> <br>7) I personally have a ~/bin directory that is in my $PATH.<br>   You will need a directory in your home that is in your             <br>   $PATH. We will assume from this point that you have such<br>   directory already in your $PATH.<br> <br>8) Create a file called ssh-to on local-machine and put it in your ~/bin directory.<br> <br>   In this file put this sweet little script ...<br><STRONG><br>#-------------snip------------<br>#!/bin/sh<br> <br>ssh `basename $0` $*<br>#-------------snip------------<br></STRONG><br>9) Save the file to ~/bin/ssh-to on local-machine and make it executable.<br>   ie: <I><B>$ chmod 700 ~/bin/ssh-to</B></I><br> <br>10) On local-machine type this command...<br> <br><I><B>    $ cd ~/bin</B></I><br> <br>11) On local-machine type this command...<br> <br><I><B>    $ ln -s ssh-to remote-machine</B></I><br> <br>    Tip: If you have an alias in your /etc/hosts file for <br>    the remote-machine use those it will make it even nicer.<br> <br>12) On local-machine type this command...<br> <br><I><B>    $ remote-machine</B></I><br> <br>     Sweet. You should have logged right in to the remote-machine.<br> <br>13) Now that you have this setup try this cool stuff....<br>    On local-machine of course.<br> <br><I><B>    $ remote-machine uptime</B></I><br> <br><I><B>    $ remote-machine ls</B></I><br> <br><I><B>    $ remote-machine any-command-you-want-to-execute-on-remote-machine</B></I><br> <br>14) Now just repeat these steps for each remote-machine<br>    that you choose. <br> <br>15) Another nice side affect of this is that "scp"<br>    and "sftp" will not require a passwd either :)<br> <br>I hope this helps someone.<br> <br>&raquo;<A HREF="http://linuxtux.org/howtos/ssh-stuff.txt" >linuxtux.org/howtos/ssh-stuff.txt</A>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10569302</guid>
<pubDate>Mon, 21 Jun 2004 15:01:07 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10423150</link>
<description><![CDATA[<A HREF="/useremail/u/165137"><b>Drunkula</b></A> : Gentoo has always been very well documented (at least as long as I've been using Gentoo).  But you know what?  They just keep getting better!<br><SMALL>--<br>I just love scanning for lifeforms!</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10423150</guid>
<pubDate>Fri, 04 Jun 2004 19:33:47 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10420700</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> :  <BLOCKQUOTE><SMALL>said by  SuperJudge <A HREF="/useremail/u/720783"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL>said by  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>when installing gentoo(www.gentoo.org) besure to read ALL the directions :) <HR></BLOCKQUOTE>That is the damn truth.  Keep the installation help page on another computer screen or print it out (on 29 sheets of paper).<br> <HR></BLOCKQUOTE>links www.gentoo.org :)<br><SMALL>--<br>Updated My Journal<BR><A HREF="http://www.tweakersparadise.com">TP&C</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10420700</guid>
<pubDate>Fri, 04 Jun 2004 14:26:51 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10390699</link>
<description><![CDATA[<A HREF="/useremail/u/858578"><b>moyix</b></A> : Another way to convert a .deb to a tar/gz file is to just extract it using the dpkg-deb command and then tar up the resulting directory. This can be automated with the following script:<br><div class="code"><PRE><span class="codetext">#!/bin/sh<br> <br>tdir=`mktemp -d`<br>dpkg-deb -x $1 "$tdir"<br>tar czCf "$tdir" ${1/.deb/.tar.gz} .<br>rm -rf "$tdir"<br></SPAN></PRE></DIV><br>Note that just untarring that tgz in the root directory is not usually enough to install the package! Most Debian packages also have scripts that are run before and/or after the files are unpacked, and such packages will often not work correctly without them.<br><br>Random bonus tip:<br>In bash, type Ctrl-r to start a reverse history search. As you type in some characters, the command history will be searched, and the most recent command that contains the string you've typed will be displayed. You can hit Ctrl-r again to show the next-to last match, again for the next-to-next-to last one, etc. When you find the command you wanted, just hit enter to execute it, or the arrow keys to leave the search mode and alter the command before executing it.<br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10390699</guid>
<pubDate>Tue, 01 Jun 2004 05:11:34 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,10371289</link>
<description><![CDATA[<A HREF="/useremail/u/1015009"><b>gbell72</b></A> : Out of curiosity is there a simple way to hide all processes besides the actual users processes as there is in FreeBSD on linux.<br>On FreeBSD I use in sysctl.conf kern.show_allprocesses=0 anything similar on Linux? Using Gentoo 2004.1<br><br>thanks<br>Gardner]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10371289</guid>
<pubDate>Sat, 29 May 2004 15:40:40 EDT</pubDate>
</item>

<item>
<title>Re: Setting lilo password.</title>
<link>http://www.dslreports.com/forum/remark,10158501</link>
<description><![CDATA[<A HREF="/useremail/u/655964"><b>jdong</b></A> :  <BLOCKQUOTE><SMALL>said by  Spike401 <A HREF="/useremail/u/622665"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>I noticed people get the "shock" when they can just "linux single" and get an init 1 login without any authentication.<br> <HR></BLOCKQUOTE><br><br>The idea is pretty cool, but still nothing stops a person from going to your computer with a GRUB floppy/CD.<br><SMALL>--<br>WASTING TIME spelled backwards is... :)</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,10158501</guid>
<pubDate>Wed, 05 May 2004 10:54:22 EDT</pubDate>
</item>

<item>
<title>Re: Display WAN IP</title>
<link>http://www.dslreports.com/forum/remark,9698816</link>
<description><![CDATA[<A HREF="/useremail/u/898435"><b>sr1515</b></A> :  <BLOCKQUOTE><SMALL>said by  deblin <A HREF="/useremail/u/465839"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Cool, didn't work here for some reason... <br> <HR></BLOCKQUOTE><br>That's because my post is missing the "less than" symbol in the last index.  Now after seeing your post, I realised how to correctly post such data.  Live and learn... :)<br><br>Here's the corrected output:<br><div class="code"><PRE><span class="codetext">wget -q -O - www.myip.com | awk '{print substr($1,index($1,"Y")) " WAN " $2 " " $3 " " sub<br> *str($4,1,index($4,"&lt;")-1)}'<br><br>(*) WARNING 1 long line(s) split<br></SPAN></PRE></DIV><br>I find your versions better than mine.  Thanks!<br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9698816</guid>
<pubDate>Wed, 17 Mar 2004 00:46:33 EDT</pubDate>
</item>

<item>
<title>Re: Display WAN IP</title>
<link>http://www.dslreports.com/forum/remark,9698755</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : Cool, didn't work here for some reason, but I was able to use perl to get it working:<br><br><div class="code"><PRE><span class="codetext">wget -q -O - www.myip.com | perl -pe 's/.*ip is (&#91;^&lt;&#93;+).*/$1\n/ig'<br></SPAN></PRE></DIV><br>or for the perl shy :) try:<br><br><div class="code"><PRE><span class="codetext">wget -q -O - www.myip.com | cut -d' ' -f4 | cut -d\&lt; -f1<br></SPAN></PRE></DIV>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9698755</guid>
<pubDate>Wed, 17 Mar 2004 00:34:19 EDT</pubDate>
</item>

<item>
<title>Display WAN IP</title>
<link>http://www.dslreports.com/forum/remark,9698698</link>
<description><![CDATA[<A HREF="/useremail/u/898435"><b>sr1515</b></A> : Here's a quick and dirty script to display the WAN IP (behind router).  Not foolproof but it does the job.<br><br>#!/bin/bash<br># Obtain WAN IP from www.myip.com and output to console<br>#<br>wget -q -O - www.myip.com | awk '{print substr($1,index($1,"Y")) " WAN " $2 " " $3 " " substr($4,1,index($4,"")-1)}'<br><br>Note: the last index character which is missing is the "less than" symbol which gets clobbered when posting.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9698698</guid>
<pubDate>Wed, 17 Mar 2004 00:25:45 EDT</pubDate>
</item>

<item>
<title>Re: Watch those worm probes :)</title>
<link>http://www.dslreports.com/forum/remark,9684840</link>
<description><![CDATA[<A HREF="/useremail/u/465839"><b>deblin</b></A> : heh, halt -p is less characters :P<br><br>Actually, I don't enable ACPI and AMP so I don't think halt -p or poweroff would work for me anyway. I rarely shut my box down anyway, except to install new hardware.<br><SMALL>--<br>"I drank what?" -Socrates</SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9684840</guid>
<pubDate>Mon, 15 Mar 2004 16:33:54 EDT</pubDate>
</item>

<item>
<title>Re: Watch those worm probes :)</title>
<link>http://www.dslreports.com/forum/remark,9587106</link>
<description><![CDATA[<A HREF="/useremail/u/711011"><b>Stevica</b></A> : Linux RedHat<br> "poweroff"<br>Easyest way to power down :P]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9587106</guid>
<pubDate>Fri, 05 Mar 2004 08:18:35 EDT</pubDate>
</item>

<item>
<title>Re: Watch those worm probes :)</title>
<link>http://www.dslreports.com/forum/remark,9444828</link>
<description><![CDATA[<A HREF="/useremail/u/370157"><b>dpreview</b></A> : :D<div class="borderless"><TABLE WIDTH=95% align=center border=0 CELLPADDING=4"><TR><TD ALIGN=CENTER VALIGN=CENTER BGCOLOR=#000000 nwrap WIDTH=33%><A HREF="/speak/slideshow/9444828?c=536822&ret=L2ZvcnVtL3I2MTc4MDA4LnhtbA%3D%3D"><IMG TITLE="3472 bytes" BORDER=0 WIDTH=125 HEIGHT=125 SRC="/r0/download/536822~579c4cba4e1db20a4e39fb778369069a/image.bmp"></A></TD></TABLE></div>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9444828</guid>
<pubDate>Thu, 19 Feb 2004 19:58:36 EDT</pubDate>
</item>

<item>
<title>Re: Watch those worm probes :)</title>
<link>http://www.dslreports.com/forum/remark,9060227</link>
<description><![CDATA[<A HREF="/useremail/u/177823"><b>kleeman</b></A> : A fantastic compendium of information can be found at this website<br>&raquo;<A HREF="http://togaware.com/linux/survivor/" >togaware.com/linux/survivor/</A><br><br>Found it when I checked out an attendee at the Oz linux show in Adelaide (featuring Linus and a trail of fanboys ;-))]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,9060227</guid>
<pubDate>Mon, 12 Jan 2004 21:34:49 EDT</pubDate>
</item>

<item>
<title>Watch those worm probes :)</title>
<link>http://www.dslreports.com/forum/remark,8548743</link>
<description><![CDATA[<A HREF="/useremail/u/878241"><b>JohnInSJ</b></A> : Ok, maybe not... but watch access hosts in apache.<br><br>Make a file: <br>$ more accesswatch.sh<br>#!/bin/bash<br>cat access_log | awk '{print $1}' | sort | uniq -c<br><br>Then in a terminal run it via watch:<br>$watch -d -n 60 ./accesswatch.sh<br><br>Now every minute you'll get an updated (with differences highlighted) list of accessing hostnames with their count of hits, like this:<br><br>Every 60s: ./accesswatch.sh       Wed Nov 19 14:01:49 2003<br><br>      1 211.43.205.XXX<br>      3 68.41.40.XXX<br>      3 68.52.63.XXX<br>      1 cablemodem-222-XXX.cableonda.net<br>     13 pcp02131XXXpcs.galitn01.tn.comcast.net<br>     13 pcp04051XXXpcs.wbrmfd01.mi.comcast.net<br>      1 ppp-64-115-69-XXX.broadviewnet.net<br><br>(XXXd to protect the innocent, and the guilty)<br><br>"Fun" to watch as worms spread within a subnet and you get hit by progressively higher ip addresses within a subnet. Sigh.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8548743</guid>
<pubDate>Wed, 19 Nov 2003 17:05:46 EDT</pubDate>
</item>

<item>
<title>Easy Symbolic Link In KDE</title>
<link>http://www.dslreports.com/forum/remark,8490642</link>
<description><![CDATA[<A HREF="/useremail/u/652505"><b>Happyrat</b></A> : An easy way to create a symbolic link in KDE is to open two instances of Konqueror and just drag the file to its destination directory then select "Link Here" from the menu that pops up.<br><SMALL>--<br>AFTER the pin is pulled, Mr. Grenade is no longer our FRIEND...&raquo;<A HREF="http://www.ratrancher.com" >www.ratrancher.com</A></SMALL>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8490642</guid>
<pubDate>Wed, 12 Nov 2003 23:25:51 EDT</pubDate>
</item>

<item>
<title>Setting lilo password.</title>
<link>http://www.dslreports.com/forum/remark,8295081</link>
<description><![CDATA[<A HREF="/useremail/u/622665"><b>Spike401</b></A> : I noticed people get the "shock" when they can just "linux single" and get an init 1 login without any authentication.<br><br>It doesnt have to be this way,<br>In the header of your lilo.conf file, add these 2 lines.<br><br>password=""<br>restricted<br><br>example:<br><br>prompt<br>timeout=10<br>default=linux<br>boot=/dev/hda<br>password=""<br>restricted<br>install=text<br>change-rules<br>reset<br>lba32<br><br>image=/boot/vmlinuz-2.4.22<br>        append="idebus=33 ide0=0x1f0,0x3f6,14 ide1=0x170,0x376,15 mem=nopentium nomodules"<br>        label=linux<br>        read-only<br>        root=/dev/hda1<br>        vga=792<br><br>When you reload lilo, it will ask you to enter a password, enter your root pass, confirm it.<br>This will create a /etc/lilo.conf.shs file with a password hash. This file is not readable by anyone but root.<br><br>When the lilo prompt comes up at next reboot, typing "linux single" will prompt for the password you inputted earlier on. You cannot append a line after the kernel version you wish to boot, else it will ask for the password. Booting "linux" alone will be fine, but typing "linux single" or "linux init=/bin/sh" isnt going to get a would be intruder very far. Having this along with bios password and being unable to boot from any media makes for a more secure system physically.<br><br>-----------------<br><br>Lowercasing all filenames in a directory:<br>Sometimes its better to have lowercase names in that directory of pictures or other stuff you want to use in your webpage, etc.<br>for f in *; do mv "$f" "`echo $f | tr '[:upper:]' '[:lower:]'`"; done<br>This will lowercase all filenames in a given directory.<br>Switching upper with lower will reverse the process.<br><SMALL>--<br>Linux: Telling Microsuck where to go since 1991.</SMALL><br><i>[text was edited by author 2003-10-22 09:47:24]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8295081</guid>
<pubDate>Wed, 22 Oct 2003 09:43:21 EDT</pubDate>
</item>

<item>
<title>This is the best thread ever.</title>
<link>http://www.dslreports.com/forum/remark,8285172</link>
<description><![CDATA[<A HREF="/useremail/u/630606"><b>lanboyo</b></A> : I am busy capturing it to text.<br><br>Okay...<br>1.<br><br>To see what ports are open on a linux box and what process is listening on them....<br><br>netstat -tupan<br><br>2.<br>to replace variable whitespace with a single space<br><br>sed s/\ \ */\ /g<br><br>...useful for ordering output into parsable text...<br><br>so you have ps -auxwww | grep process\ with\ option  | grep -v grep<br><br>and you just want the process ids<br><br>but cut gives you the whole line... It wants TABs<br><br>ps -auxwww | grep process\ with\ option  | grep -v grep | sed s/\ \ */\ /g | cut -d\  -f2<br><br>3.<br>sort -u will sort lines uniquely.. No repeats for those chatty log files.<br><br>4. learn some regular expressions if you are serious.<br><br>grep sammmy[1234] matches sammmy1 sammy2 sammy3 and sammy4 but not sammy5<br><br>5.<br>On RedHat linux, All that stuff that scrolls by during boot up is put into /var/log/dmesg<br><br>Only way I know how much memory I have.<br><br>6.<br>ssh port forwarding is a lifesaver... putty and cygwin both can forward ports to remote boxes on windows. Need to get to your mail server? forward local 25 thru your border firewall.<br><br>You can stack multiple ssh sessions this way by forwarding ssh sessions with new forwards.<br><br>ssh  -L 11101:secondhost:22 bob@firsthost<br>ssh -p 11101 -L 11102:thirdhost:22 bob@localhost<br>ssh -p 11102  bob@localhost<br><br>strict key checking is a problem here...<br><br>7. <br>If you are a network security person... NOTE: your users can do that last one too and allow connections on the remote box to come back with the -R flag.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8285172</guid>
<pubDate>Tue, 21 Oct 2003 07:20:39 EDT</pubDate>
</item>

<item>
<title>Re: User tracking in Unix</title>
<link>http://www.dslreports.com/forum/remark,8260089</link>
<description><![CDATA[<A HREF="/useremail/u/663510"><b>Nutty Hiker</b></A> : I don't know if this belongs, so if it doesn't, feel free to whack it.<br><br>I found a nifty PERL script that converts .deb file to .tar.gz.<br><br>&raquo;<A HREF="http://www.miketaylor.org.uk/tech/deb/" >www.miketaylor.org.uk/tech/deb/</A><br><small>--<br>We want <A HREF="http://www.petitiononline.com/msiepng/petition.html">PNG</A>, dammit!</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8260089</guid>
<pubDate>Fri, 17 Oct 2003 23:06:51 EDT</pubDate>
</item>

<item>
<title>Re: User tracking in Unix</title>
<link>http://www.dslreports.com/forum/remark,8032923</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> :  <BLOCKQUOTE><SMALL>said by  paul1238 <A HREF="/useremail/u/233421"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>A well written system startup procedure [should normally delete the utmp file when the system boots. <HR></BLOCKQUOTE>Yah, sure, but what if you only <A HREF="http://www.unix-girl.com/blog/archives/001143.html">reboot every two years</A>? :-)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8032923</guid>
<pubDate>Mon, 22 Sep 2003 10:34:48 EDT</pubDate>
</item>

<item>
<title>Re: User tracking in Unix</title>
<link>http://www.dslreports.com/forum/remark,8026757</link>
<description><![CDATA[<A HREF="/useremail/u/423938"><b>davidsmind</b></A> : Oh, I am sorry. I was commenting on the following:<br><br><I>"Another issue, is that applications may or may not actually generate the entries. Some terminal applications, (like kconsole, if I remember correctly) will generate utmp entries whenever it is spawned. This leads to many extraneous user login entries."</I><br><br>I found it kinda slanderous. Since I use konsole all the time and I've never seen this beheiveor, I was just clearing a small misconseption up.<br><br>and BTW, I am only kind of aware of how utmp entries work....but I know enough to know that konsole doesn't open up one per window.<br><small>--<br>"Of course I'm paranoid, everyone's trying to kill me."</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8026757</guid>
<pubDate>Sun, 21 Sep 2003 15:52:13 EDT</pubDate>
</item>

<item>
<title>Re: User tracking in Unix</title>
<link>http://www.dslreports.com/forum/remark,8024938</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> : Do you have a question about how utmp entries work? I didn't quite understand the issue in your post. <br><br>When an application is used normally, you should expect that the utmp database will not contain any orphaned entries. Applications that properly process signals such as SIGINT, SIGHUP, etc. should also not leave any orphaned entries.<br><br>Applications that manipulate the utmp databases use the C library functions setutent(), getutent(), endutent(), etc. These functions are actually not portable.<br><br>An orphan entry is persisted in the utmp database when an application fails to exit properly as I previously explained. For example, start up a few applications that create utmp entries, then simply power off the system. That's generally a sure way to create an orphaned utmp entry. Bugs in software that do not clean up the utmp database can also leave orphaned entries.<br><br>A well written system startup procedure should normally delete the utmp file when the system boots. <br><br>I personally do not have a utmp file on any of my systems, hence I do not have programs like <B>who</B>, and <B>users</B>. IMO, querying the kernel process table with <B>ps</B> is a better method of determining what users might be logged in.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8024938</guid>
<pubDate>Sun, 21 Sep 2003 11:18:58 EDT</pubDate>
</item>

<item>
<title>Re: User tracking in Unix</title>
<link>http://www.dslreports.com/forum/remark,8019629</link>
<description><![CDATA[<A HREF="/useremail/u/423938"><b>davidsmind</b></A> : I just opened up 24 konsole's, it didn't generate any extra utmp entries. I closed them all as well as loging out, and the processes are not ophaned.<br><small>--<br>"Of course I'm paranoid, everyone's trying to kill me."</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8019629</guid>
<pubDate>Sat, 20 Sep 2003 17:01:30 EDT</pubDate>
</item>

<item>
<title>My Little contribution</title>
<link>http://www.dslreports.com/forum/remark,8017641</link>
<description><![CDATA[<A HREF="/useremail/u/858614"><b>sblaze</b></A> : I wrote some stuff awhile back for &raquo;<A HREF="http://www.linuxguru.net" >www.linuxguru.net</A><br>Although I moved all my work to &raquo;<A HREF="http://nixn00b.net" >nixn00b.net</A> after a disagreement<br><br>This should prove useful for novice to moderate users. It covers a variety of stuff. Some conventional some not. Suggesstions, comments, and critiques welcomed.<br><br>Thanks ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,8017641</guid>
<pubDate>Sat, 20 Sep 2003 12:14:11 EDT</pubDate>
</item>

<item>
<title>User tracking in Unix</title>
<link>http://www.dslreports.com/forum/remark,7981644</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> : Every few months, there is a post about how to log out users that appear to be on a unix system. The typical post is that a <B>who</B> command was issued and extra users appear to be logged in. <br><br>If the user is truly still active, then the command <B>ps -aelf | grep <I>username</I></B> can be issued to find the process ids of any interactive shell. The <B>kill</B> command is then used to terminate the process.<br><br>However, typically no extraneous processes are found but <B>who</B> still reports that users are logged in. <br><br>The process of tracking what user is logged into a unix system is actually a bit odd. It is a sort of a cooperative behavior between applications. Most applications will write a record into a file called utmp or wtmp to indicate that a user has logged in. And applications that want to query to see how many users are logged in will query the database.<br><br>If an application does not want to record a connection it doesn't have to. Even in the application xterm, it possible to use the -ut option to tell it not to write a utmp record so that it will not appear that there is another user logged in.<br><br>Programs like <B>who</B> and <B>users</B> will read from the utmp file to determine the current logg-ed in users. One of the more annoying problems with this method is orphaned entries. (ie, the application is killed without cleaning up the log-in entry) So a login may appear but in reality does not exist.<br><br>Another issue, is that applications may or may not actually generate the entries. Some terminal applications, (like kconsole, if I remember correctly) will generate utmp entries whenever it is spawned. This leads to many extraneous user login entries. This has been a point of much debate. For example, should the NFS server or the SMB server generate a utmp entry whenever someone connects to it. What about the mail server? Etc.<br><br>If orphan utmp entries occur, the easiest brute force solution is to delete the utmp file. The utmp file location varies but it can usually be found in <I>/var/run/utmp</I> or <I>/var/adm/utmp</I>. Deleting the file must be done by the root user but it can be performed on a running system.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7981644</guid>
<pubDate>Tue, 16 Sep 2003 13:02:21 EDT</pubDate>
</item>

<item>
<title>Re: remove CTRL-M characters from a file in UNIX</title>
<link>http://www.dslreports.com/forum/remark,7897780</link>
<description><![CDATA[<A HREF="/useremail/u/823540"><b>Thasp6</b></A> : If you're going to install nice new fonts like the bitstream vera ones, instead of spending a month trying to get mozilla or something to work without crashing, GIVE THE FONTS PERMISSIONS TO BE READ!!! This drove me nuts. <br><small>--<br>Rejection is having your hand fall asleep while you're masturbating. This has never happened to me before. </small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7897780</guid>
<pubDate>Sun, 07 Sep 2003 02:27:15 EDT</pubDate>
</item>

<item>
<title>remove CTRL-M characters from a file in UNIX</title>
<link>http://www.dslreports.com/forum/remark,7875285</link>
<description><![CDATA[<A HREF="/useremail/u/816178"><b>gniknalu</b></A> : Something useful yet many don't know about it:<br><br>Using sed (the stream editor)- try this:<br>  sed -e "s/^M//" FileName > NewFileName<br><br>To get ^M you hold down the CTRL key, press V then while still holding CTRL, press M. <br><br>While using vi:<br>  % vi filename<br><br>While in vi and vim, hit : to get into command mode, then type:<br>  :%s/^M//g<br><br>While in Emacs, go to the beginning of the document and<br>Type:<br>  M-x replace-string RET C-q C-m RET RET<br><br>where "RET" means press-the-return-key and C-q and C-m mean hold-the-CTRL-key-and press-the-m-(or q)-key.<br><br><i>[text was edited by author 2003-09-04 18:59:08]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7875285</guid>
<pubDate>Thu, 04 Sep 2003 16:56:46 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7792073</link>
<description><![CDATA[<A HREF="/useremail/u/383145"><b>freerock</b></A> : removing spaces from filenames:<br><br>for i in *; do mv "$i" "`echo $i|tr '\ ' '_'`";done]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7792073</guid>
<pubDate>Tue, 26 Aug 2003 18:05:08 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7767400</link>
<description><![CDATA[<A HREF="/useremail/u/177823"><b>kleeman</b></A> : Wow this thread is getting a bit undersubscribed. Anyway here is a good tip: For a Bayesian spam filter to use with Evolution give popfile a try. The documentation is great and the results are very nice. It also works quite a bit faster than spamassassin. If you want a script to start it at bootup (the pop server running popfile) check out the forum page. In evolution all you do is change your username to server: oldusername and your server to 127.0.0.1. Also you add a filter rule which checks for a "Specific header" (enter  "X-Text-Classification") contains (enter: spam (or the bucket name you have chosen)) then move to (enter spam folder).  Took only 20 mins to set up and is working well so far :-)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7767400</guid>
<pubDate>Sat, 23 Aug 2003 21:38:34 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7540013</link>
<description><![CDATA[<A HREF="/useremail/u/530791"><b>Techie2000</b></A> :  <BLOCKQUOTE><SMALL>said by  ftzsee <A HREF="/useremail/u/520788"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>It's installed with the bsd-games package in Slackware, I think.<HR></BLOCKQUOTE>In Gentoo you can just "emerge wtf" or you can go to &raquo;<A HREF="http://www.mu.org/~mux/wtf/" >www.mu.org/~mux/wtf/</A> to download it.<br><small>--<br>"With the first link, the chain is forged. The first speech censored, the first thought forbidden, the first freedom denied, chains us all irrevocably." - Captain Jean-Luc Picard</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7540013</guid>
<pubDate>Wed, 30 Jul 2003 12:02:37 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7445709</link>
<description><![CDATA[<A HREF="/useremail/u/132602"><b>bobrk</b></A> :  <BLOCKQUOTE><SMALL>said by  Evolution <A HREF="/useremail/u/498311"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>This tip comes in handy especially when viewing Windows partitions through the console. Whenever you encounter a directory with 2 words in it, like "Program Files" you cannot simply enter cd /mnt/Windows/Program Files/ to enter the Program Files directory. You must enter /mnt/Windows/Program\ Files/ to enter into the Program Files folder. Another small little tip for this thread :-)<br> <HR></BLOCKQUOTE>You can also use name completion in most shells to force the shell to find the file names. So you'd type<PRE>cd /mnt/Windows/P</PRE> and then hit the <B>tab</B> key. Assuming that there are two directories "Program Files" and "Programs" or something like that, the tab key would cause the line to become <PRE>cd /mnt/Windows/Program</PRE> and the terminal would beep, telling you to add a unique letter. In this case, you'd type <B>space</B> and <B>tab</B> and the completer would then change the line to <PRE>cd /mnt/Windows/Program Files/</PRE> This takes much longer to type and read than it does to just do, so try it! I know it works in tcsh, so it probably works in bash as well.<br><small>--<br><A HREF="http://www.bobrk.com/">bobrk.com</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7445709</guid>
<pubDate>Sat, 19 Jul 2003 21:29:37 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7412311</link>
<description><![CDATA[<A HREF="/useremail/u/498311"><b>Evolution</b></A> : oh ok didnt see the quotes. I guess thats a new tip then, two ways to enter a directory with separated filenames.<br><small>--<br>&raquo;<A HREF="http://www.chrisnylen.com" >www.chrisnylen.com</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7412311</guid>
<pubDate>Tue, 15 Jul 2003 23:44:41 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7408028</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> : That works for me, but you must have the " and " around it.<br><small>--<br><B>Bush/Cheney 2004</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7408028</guid>
<pubDate>Tue, 15 Jul 2003 16:00:27 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7402956</link>
<description><![CDATA[<A HREF="/useremail/u/498311"><b>Evolution</b></A> : Nope, that doesn't work. It will look for the directory called "Program" and it is necessary to have that backslach on there.<br><small>--<br>&raquo;<A HREF="http://www.chrisnylen.com" >www.chrisnylen.com</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7402956</guid>
<pubDate>Tue, 15 Jul 2003 00:08:10 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7397363</link>
<description><![CDATA[<A HREF="/useremail/u/809372"><b>sokhapkin</b></A> :  <BLOCKQUOTE><SMALL>said by  Evolution <A HREF="/useremail/u/498311"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>This tip comes in handy especially when viewing Windows partitions through the console. Whenever you encounter a directory with 2 words in it, like "Program Files" you cannot simply enter cd /mnt/Windows/Program Files/ to enter the Program Files directory. You must enter /mnt/Windows/Program\ Files/ to enter into the Program Files folder. Another small little tip for this thread :-)<br> <HR></BLOCKQUOTE><br><br>cd "/mnt/Windows/Program Files" will work too.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7397363</guid>
<pubDate>Mon, 14 Jul 2003 12:18:18 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7396966</link>
<description><![CDATA[<A HREF="/useremail/u/498311"><b>Evolution</b></A> : This tip comes in handy especially when viewing Windows partitions through the console. Whenever you encounter a directory with 2 words in it, like "Program Files" you cannot simply enter cd /mnt/Windows/Program Files/ to enter the Program Files directory. You must enter /mnt/Windows/Program\ Files/ to enter into the Program Files folder. Another small little tip for this thread :-)<br><small>--<br>&raquo;<A HREF="http://www.chrisnylen.com" >www.chrisnylen.com</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7396966</guid>
<pubDate>Mon, 14 Jul 2003 10:54:19 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7297876</link>
<description><![CDATA[<A HREF="/useremail/u/585967"><b>jknowler</b></A> : My dialup ISP dumps me after 480 minutes, so I use this all the time to show time connected and connect speed of a WvDial Dialup connection:<br><PRE><br>grep CONNECT /var/log/messages | tail -n 1<br>Jul 3 00:02:45 sulu WvDial: CONNECT 44000/ARQ/V90/LAPM/V42BIS<br></PRE><br><I>edit: Added Result</I><br><br><i>[text was edited by author 2003-07-03 01:29:13]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7297876</guid>
<pubDate>Thu, 03 Jul 2003 01:20:36 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7285560</link>
<description><![CDATA[<A HREF="/useremail/u/834526"><b>riskable</b></A> : In Solaris you can get a great swap command output with the following command:<br><br>swap -s | /usr/bin/tr -d /k/ | awk '{u = $9} {a = $11} {t = u+a} END {print "Usage is at "u/t*100"% ""\n"a/t*100"% is Available"}'<br><br>It'll print your swap usage in percentage--very handy.  Example:<PRE><br>Usage is at 48.6197%<br>51.3803% is Available</PRE><br><br>Also, on most Linux systems in most commands you can utilize the -h option to make things "human readable".<br><br>For example, the difference in df:<br><br><PRE><br>root@hiro/etc/rc.d)$ df -k<br>Filesystem           1K-blocks      Used Available Use% Mounted on<br>/dev/hda1              9623548   1931312   7692236  21% /<br>none                    160172         0    160172   0% /dev/shm<br>/dev/md0              58631548  51250628   7380920  88% /home<br>root@hiro/etc/rc.d)$ df -h<br>Filesystem            Size  Used Avail Use% Mounted on<br>/dev/hda1             9.2G  1.9G  7.3G  21% /<br>none                  156M     0  156M   0% /dev/shm<br>/dev/md0               56G   49G  7.0G  88% /home<br>root@hiro/etc/rc.d)$</PRE><br><br>Makes things MUCH easier to read.<br><br>The lsof command lists currently open files in a system, but it can also be used to tell if a file is in use:<br><br><PRE>root@hiro/etc/rc.d)$ lsof /var/log/messages<br>COMMAND  PID USER   FD   TYPE DEVICE   SIZE  NODE NAME<br>syslogd 1067 root    5w   REG    3,1 357610 82313 /var/log/messages</PRE><br><br>However, it's not just limited to files.  If you want to know what process is taking up a certain port on your system, you can very easily check using lsof:<br><br><PRE>root@hiro/etc/rc.d)$ lsof -i :80<br>COMMAND   PID   USER   FD   TYPE   DEVICE SIZE NODE NAME<br>httpd    1532 apache   29u  IPv4    60417       TCP *:http (LISTEN)<br>httpd    5128   root   29u  IPv4    60417       TCP *:http (LISTEN)<br>httpd   10161 apache   29u  IPv4    60417       TCP *:http (LISTEN)<br></PRE><br><br>You can also figure out what applications (and ports) are listening on a certain IP:<br><br><PRE>root@hiro/etc/rc.d)$ lsof -i @10.0.0.1<br>COMMAND   PID     USER   FD   TYPE   DEVICE SIZE NODE NAME<br>named    1309    named   11u  IPv4     3326       UDP hiro.youknowwhat.com:domain<br>named    1309    named   12u  IPv4     3327       TCP hiro.youknowwhat.com:domain (LISTEN)<br>named    1310    named   11u  IPv4     3326       UDP hiro.youknowwhat.com:domain<br></PRE><br><br>Don't know what port "domain" is?  Check it in the /etc/services file:<br><br><PRE>root@hiro/etc/rc.d)$ grep domain /etc/services<br>domain          53/tcp                          # name-domain server<br>domain          53/udp</PRE><br><br>I'm sure I'll think of some more]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7285560</guid>
<pubDate>Tue, 01 Jul 2003 21:03:31 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7254093</link>
<description><![CDATA[<A HREF="/useremail/u/165137"><b>Drunkula</b></A> : Okay another one from the book.  So simple but cool!<br><br>To backup across the net using SSH (assuming /etc as the source to backup and bkuphost is destination hostname or IP):<br><BLOCKQUOTE>tar zvcf - /etc | ssh bkuphost "cat > destfile.tgz"</BLOCKQUOTE>You could also replace the destfile.tgz with /dev/tape to backup to tape.<br><small>--<br>Beer is proof that God loves us, and wants us to be happy.  -- Benjamin Franklin</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7254093</guid>
<pubDate>Sat, 28 Jun 2003 12:09:34 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7248934</link>
<description><![CDATA[<A HREF="/useremail/u/165137"><b>Drunkula</b></A> : Add the following alias to your .profile then go to /var/mail and issue the ducks command to see which of your email users is sucking up the most diskspace.<br><br><BLOCKQUOTE>alias ducks='du -cks * |sort -rn |head -11'</BLOCKQUOTE>Okay I got it from a book but I like it...<br><br>Follow up:  This tip came from the book "Linux Server Hacks" by Rob Flickenger, published by O'Reilly.  I only got through chapter 1 so far but it seems to have some great info.  However it's geared not so much for newbies but for those with a half-way decent understanding of Linux.<br><i>[text was edited by author 2003-06-27 20:41:28]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7248934</guid>
<pubDate>Fri, 27 Jun 2003 20:31:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7224618</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> :  freerock <A HREF="/useremail/u/383145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> told me about this:<br><br> <BLOCKQUOTE><SMALL>said by  ftzsee <A HREF="/useremail/u/520788"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>'s ssh window:</SMALL><HR><TT>[joel@milo joel]$ wtf is bash<br>bash: bash                 (1)  - GNU Bourne-Again SHell<br>bash [builtins]      (1)  - bash built-in commands, see bash(1)<br>[joel@milo joel]$ wtf is shutdown<br>shutdown: shutdown             (2)  - shut down part of a full-duplex connection<br>shutdown             (8)  - bring the system down<br>[joel@milo joel]$wtf is wtf<br>WTF: {what,where,who,why} the f*ck<br></TT><br><HR></BLOCKQUOTE>It's installed with the bsd-games package in Slackware, I think.<br><small>--<br><B>Bush/Cheney 2004</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7224618</guid>
<pubDate>Wed, 25 Jun 2003 15:49:06 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7183285</link>
<description><![CDATA[<A HREF="/useremail/u/177823"><b>kleeman</b></A> : If you need to connect to secure remote files and edit them kde is your friend: In any kde app (eg konqueror, kwrite, kate, kdevelop.....) simply type in the open box "sftp://user@servername" where your username is user and your remote server is servername and that is sftp not s>>ftp. The latest versions on konq give beautiful tree structure for your remote file system and you can open files with a click with kwrite or kate both of which have great source highlighting facilities. When your done you just save and the remote file is updated. I am very impressed  by this kde feature, it beats the crap out of using Stallman's torture vehicle emacs and its tramp kludge addon. <br><br> ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7183285</guid>
<pubDate>Fri, 20 Jun 2003 23:27:16 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7149664</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> :  <BLOCKQUOTE><SMALL>said by  nixen <A HREF="/useremail/u/698757"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Why issue the <TT>sync</TT>'s?<HR></BLOCKQUOTE>Because if you've been doing it that way for 20 years, habits are hard to break :-)<br><br>Steve<br><small>--<br>Stephen J. Friedl * Security Consultant * Tustin, California USA * <A HREF="http://www.unixwiz.net">my web site</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7149664</guid>
<pubDate>Tue, 17 Jun 2003 19:07:38 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7145297</link>
<description><![CDATA[<A HREF="/useremail/u/698757"><b>nixen</b></A> :  <BLOCKQUOTE><SMALL>said by  kj6loh2 <A HREF="/useremail/u/659628"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL>said by  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> myother fav command is<br><br>shutdown -r now<br><br>weeee <HR></BLOCKQUOTE><br><br>why not use sync;sync;init 6?<br> <HR></BLOCKQUOTE><br>Why issue the <TT>sync</TT>'s? Unless you are shutting down via halt/fasthalt, the shutdown and/or init N commands both result in syncs.<br><br>-tom<br><small>--<br>You can be only -so- accurate with a sledgehammer.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7145297</guid>
<pubDate>Tue, 17 Jun 2003 11:14:38 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7140968</link>
<description><![CDATA[<A HREF="/useremail/u/344321"><b>bmn</b></A> : Do we have any more tips and tricks to add beside kernel features ?! ;)  <br><br>If not, we can lock this up and make some of these entries on a webpage that can be linked in the links...]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7140968</guid>
<pubDate>Mon, 16 Jun 2003 21:14:27 EDT</pubDate>
</item>

<item>
<title>Re: Linux Kernel Mode HTTP Server</title>
<link>http://www.dslreports.com/forum/remark,7121345</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> : I think this feature was pulled for 2.5 - last time I compiled a 2.5 kernel, I couldn't find it.<br><br>It's a pretty neat feature though.<br><small>--<br><B>Bush/Cheney 2004</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7121345</guid>
<pubDate>Sat, 14 Jun 2003 11:57:20 EDT</pubDate>
</item>

<item>
<title>Linux Kernel Mode HTTP Server</title>
<link>http://www.dslreports.com/forum/remark,7108088</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> : If you use Linux, did you know that there is a blazingly fast web server built into the kernel?<br><br><B>khttpd</B> is a kernel-mode web server that is part of the Linux kernel. Because it runs as a kernel module, it is much faster than it's user-mode equivalents. <br><br>If you simple need to serve up static content, check out <B>khttpd</B>. A kernel mode http server can be used to supplement web application servers as a fast static content server.<br><br><B>khttpd</B> is normally built as a kernel module. Configuration of the server is performed using the procfs interface located in <I>/proc/sys/net/khttpd</I>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7108088</guid>
<pubDate>Thu, 12 Jun 2003 22:40:34 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7060990</link>
<description><![CDATA[<A HREF="/useremail/u/823242"><b>jamies0320</b></A> : I frequently work on systems that have already, or are about to fill a filesystem (not my own doing).<br><br>I have found this to be most helpful in locating large files<br><br>assuming /var is the filesystem in question<br><br>du -ax /var |sort -nr|more<br><br>the larger files/directories will be sorted to the top, and are usually a good place to look for something that may be growing out of hand.<br><br>if you locate a file that is activly growing, you can use<br><br>fuser FILENAME<br><br>to find the process id of the user, and then<br><br>ps -ef|grep PROCESS_ID to determine who is using the file.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7060990</guid>
<pubDate>Sat, 07 Jun 2003 23:10:10 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7055045</link>
<description><![CDATA[<A HREF="/useremail/u/272943"><b>Starfish</b></A> :                                <br>This thread is awesome! :D<br>                             <br>I've already learned a few very useful tips..thank you all! :)                                 <br><small>--<br><A HREF="http://www.broadbandreports.com/faq/lifemapper/">Mapping Life on Earth</A> | <A HREF="http://www.broadbandreports.com/faq/ecology">Join the clickeroo!</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7055045</guid>
<pubDate>Sat, 07 Jun 2003 08:15:24 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,7029069</link>
<description><![CDATA[<A HREF="/useremail/u/814416"><b>RussianSpy4</b></A> : Thats a pretty spiffy site ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,7029069</guid>
<pubDate>Wed, 04 Jun 2003 14:25:16 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6991976</link>
<description><![CDATA[<A HREF="/useremail/u/177823"><b>kleeman</b></A> : Here's a great reference which is pretty comprehensive, detailed and up to date. I just used it to set up mplayer:<br><br> &raquo;<A HREF="http://beyond.linuxfromscratch.org/view/cvs/index.html" >beyond.linuxfromscratch.org/view&middot;&middot;&middot;dex.html</A>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6991976</guid>
<pubDate>Sat, 31 May 2003 10:56:59 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6987578</link>
<description><![CDATA[<A HREF="/useremail/u/487980"><b>bbrkdub</b></A> :  <BLOCKQUOTE><SMALL>quote:</SMALL><HR>While you still have connectivity, track down a couple really good networking diagnostic HOWTO pages. <HR></BLOCKQUOTE><br><br>I guess you could do that, but I'd prefer to read the man pages first.<br><small>--<br>Hope this helps...</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6987578</guid>
<pubDate>Fri, 30 May 2003 19:38:18 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6984499</link>
<description><![CDATA[<A HREF="/useremail/u/750321"><b>cprincipe</b></A> : If you don't have a good book on Linux on your desk, you can often find answer to what you need online.  However, what if you can't get online or have lost your connectivity for some reason?<br><br>While you still have connectivity, track down a couple really good networking diagnostic HOWTO pages.  Create a networking directory somewhere on your machine and save those pages into that networking directory.  If you know a little html, you could code yourself a master page with links to the other pages.  That way, if you have some problems with connectivity, you've got resources right there on your PC.  (Assuming you don't want to go out and buy a book.)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6984499</guid>
<pubDate>Fri, 30 May 2003 13:41:57 EDT</pubDate>
</item>

<item>
<title>Identifying Partitions</title>
<link>http://www.dslreports.com/forum/remark,6938738</link>
<description><![CDATA[<A HREF="/useremail/u/570732"><b>bgrundy</b></A> : You can get a list of partitions on a disk with <B>fdisk -l</B><BLOCKQUOTE>jupiter root # fdisk -l /dev/hda<br> <br>Disk /dev/hda: 200.0 GB, 200049647616 bytes<br>255 heads, 63 sectors/track, 24321 cylinders<br>Units = cylinders of 16065 * 512 = 8225280 bytes<br> <br>   Device Boot    Start       End    Blocks   Id  System<br>/dev/hda1   *         1      2550  20482843+   7  HPFS/NTFS<br>/dev/hda2          2551      2563    104422+  83  Linux<br>/dev/hda3          2564      2629    530145   82  Linux swap<br>/dev/hda4          2630     24321 174240990    5  Extended<br>/dev/hda5          2630      6454  30724281   83  Linux<br>/dev/hda6          6455      8887  19543041   83  Linux<br>/dev/hda7          8888     15261  51199123+   7  HPFS/NTFS<br>/dev/hda8         15262     20125  39070048+   c  Win95 FAT32 (LBA)<br></BLOCKQUOTE><br><br>You can then identify the partitions (i.e. different types of linux partitions with <B>file -s</B>.  <br><br><B>file -sL</B> is useful for following links, i.e. with devfs.:<BLOCKQUOTE> jupiter root # file -sL /dev/hda2<br>/dev/hda2: Linux rev 1.0 ext3 filesystem data<br>jupiter root # file -sL /dev/hda3<br>/dev/hda3: Linux/i386 swap file (new style)<br>jupiter root # file -sL /dev/hda5<br>/dev/hda5: Linux rev 1.0 ext3 filesystem data (needs journal recovery)<br></BLOCKQUOTE><br> <br> <br><small>--<br>"If you continue to use Windows, your system may become unstable"  --BSOD</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6938738</guid>
<pubDate>Sun, 25 May 2003 13:36:12 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6937308</link>
<description><![CDATA[<A HREF="/useremail/u/816355"><b>jaklein1</b></A> : I started out life as a mainframe programmer (That's IBM MainFrames).  I've always used ISPF as an editor.  Its Full Screen, wow!  Since I installed LINUX on my home PC, I've had to learn VI.  It's a steep learning curve but I find it enjoyable to use, fun, and more flexable than other editors I used (not that I have extensive experience with Pico, Nano, or Emacs).  ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6937308</guid>
<pubDate>Sun, 25 May 2003 10:12:16 EDT</pubDate>
</item>

<item>
<title>Backing up your MBR</title>
<link>http://www.dslreports.com/forum/remark,6920289</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> : Sometimes before making changes to a partition table or MBR, it is probably a good idea to perform a backup.<br><br>The partition table and the MBR is located on the first 512byte block of the active partition. So assuming that your boot disk is /dev/hda, you can backup your MBR and partition table with:<br><br><B>dd if=/dev/hda of=/tmp/hda.boot.mbr bs=512 count=1</B><br><br>This command will create a file called <I>/tmp/hda.boot</I> which will contain the MBR and partition table.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6920289</guid>
<pubDate>Fri, 23 May 2003 11:29:51 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6910281</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : Since I always forget where to do it -<br>If you ever want to change the default login messages<br>take a look at:<br><br> <BLOCKQUOTE><SMALL>quote:</SMALL><HR>/etc/issue<br>/etc/issue.net<br>/etc/motd<HR></BLOCKQUOTE><br><br>If you want to make a change simply comment out the other lines. Here is my /etc/issue.net<br> <BLOCKQUOTE><SMALL>quote:</SMALL><HR>#Red Hat Linux release 8.0 (Psyche)<br>#Kernel \r on an \m<br>This is a test system<HR></BLOCKQUOTE>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6910281</guid>
<pubDate>Thu, 22 May 2003 11:02:08 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6905777</link>
<description><![CDATA[<A HREF="/useremail/u/633207"><b>NJRob</b></A> : how about opening EMACS<br><br>bash-2.05$ emacs foo.txt<br><br>once in emacs - hit esc then the letter x<br><br>then type out the word "spook" (without the quotes)<br><br>great way to make your .sig file *heh*]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6905777</guid>
<pubDate>Wed, 21 May 2003 21:37:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6902787</link>
<description><![CDATA[<A HREF="/useremail/u/199986"><b>Clangeddin</b></A> : Ok, that is a cool little script.  Thanks!]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6902787</guid>
<pubDate>Wed, 21 May 2003 16:30:49 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6897669</link>
<description><![CDATA[<A HREF="/useremail/u/659628"><b>kj6loh2</b></A> :  <BLOCKQUOTE><SMALL>said by  elluzion <A HREF="/useremail/u/704973"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>This may be old news to many...<br>You can get access to a Linux computer without logging in by typing "linux single" at the LILO "boot:" prompt. I think you can type "linux emergency" as well and get the same effect.<br><HR></BLOCKQUOTE><br>Old news yes.  Booting in single user mode has been historically that way.  Sun and other vendors got around this by using prom passwords, which itself posed problems.  <br>In order to boot the machine you would need a master password.  So what's wrong with this you may ask?  <br>Well, what happens when this particular machine hasn't been rebooted in a long time and the administrator leaves?  and does not leave a forwarding number?  And the new administrator did not ask for the prom password and the old administrator forgot to give it?  This happens more often than you'd think.  Since no one needs this until the machine is turned off or reboot.  You do not realize the need for this prom password.  So most administrators didn't use a prom password.  This is a quick way for administrators to restore passwords, etc...<br>This is why many servers are put behind locked doors.<br> <BLOCKQUOTE><SMALL>quote:</SMALL><HR><br>It boots the computer to runlevel 1<br><HR></BLOCKQUOTE><br>you can edit /etc/runtab or whatever config file it is and edit out run level 1 if you want. <br><small>--<br>Systems administrator</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6897669</guid>
<pubDate>Wed, 21 May 2003 01:08:14 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6897557</link>
<description><![CDATA[<A HREF="/useremail/u/659628"><b>kj6loh2</b></A> :  <BLOCKQUOTE><SMALL>said by  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> myother fav command is<br><br>shutdown -r now<br><br>weeee <HR></BLOCKQUOTE><br><br>why not use sync;sync;init 6?<br><small>--<br>Systems administrator</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6897557</guid>
<pubDate>Wed, 21 May 2003 00:48:51 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6896628</link>
<description><![CDATA[<A HREF="/useremail/u/659628"><b>kj6loh2</b></A> :  <BLOCKQUOTE><SMALL>said by  Skipdawg <A HREF="/useremail/u/372465"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br>An Introduction to the Linux Command Line Interface, The Core 15 Commands <br>&raquo;<A HREF="http://www.wtlug.org/story.php/view/54/" >www.wtlug.org/story.php/view/54/</A><br><HR></BLOCKQUOTE><br><br>Very good.  This can be further broadened to most unixes if instead of less it referenced more.  gzip is still not on every unix out there.  Neither are killall, locate, dpkg, and rpm.  gcc is usually cc, unless the administrator put gcc on the system, since development packages usually are extra, whereas gcc is free!<br><small>--<br>Systems administrator</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6896628</guid>
<pubDate>Tue, 20 May 2003 22:52:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6887499</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> :  <BLOCKQUOTE><SMALL>said by  Eatmeingreek <A HREF="/useremail/u/421006"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Typing just / and then enter searches for the last pattern again.<HR></BLOCKQUOTE> Even easier is to just press "n".<br><small>--<br><B>Bush/Cheney 2004</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6887499</guid>
<pubDate>Tue, 20 May 2003 00:12:51 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6883001</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> : You can search for patterns in man pages in the same way as you search in vi - using a slash ("/".)<br><br>Say for example, that you wanted to know more about history files in bash(1). After typing "man bash", you'd type something like "/istory".  I like to leave the first letter off, so I catch both "History" and "history".<br><br>Typing just / and then enter searches for the last pattern again.  This is the same as "find next".  You can space through the man page looking for items of interest this way.<br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6883001</guid>
<pubDate>Mon, 19 May 2003 16:15:20 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6813427</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> :  <BLOCKQUOTE><SMALL>said by  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>when installing gentoo(www.gentoo.org) besure to read ALL the directions :) <HR></BLOCKQUOTE>That is the damn truth.  Keep the installation help page on another computer screen or print it out (on 29 sheets of paper).<br><small>--<br>I went to a restaurant that serves "breakfast at any time". So I ordered French Toast during the Renaissance.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6813427</guid>
<pubDate>Sun, 11 May 2003 12:09:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6788827</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> : You can use split(1) to break up large files into smaller chunks.  You can then use cat(1) to reassemble the chunks. This is useful for sending large files over email and maybe dialup.  I'd think wget -c is probably a better option for dialup, though.<br><br>Example:<br><br><BLOCKQUOTE>code:<HR><pre>[me@centaur temp]$ ls -lh<br>total 778M<br>...<br>-rw-------    1 me     me          33M Mar 21 12:23 vse701trial_linux.tar<br>...<br>[me@centaur temp]$ split -b 2m vse701trial_linux.tar <br>[me@centaur temp]$ ls -lh<br>total 811M<br>...<br>-rw-------    1 me     me          33M Mar 21 12:23 vse701trial_linux.tar<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xaa<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xab<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xac<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xad<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xae<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xaf<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xag<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xah<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xai<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xaj<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xak<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xal<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xam<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xan<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xao<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xap<br>-rw-rw-r--    1 me     me         752k May  8 11:18 xaq<br>...<br>[me@centaur temp]$ cat xa? > vsenew.tar<br>[me@centaur temp]$ ls -lh<br>total 844M<br>...<br>-rw-------    1 me     me          33M Mar 21 12:23 vse701trial_linux.tar<br>-rw-rw-r--    1 me     me          33M May  8 11:21 vsenew.tar<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xaa<br>-rw-rw-r--    1 me     me         2.0M May  8 11:18 xab<br>...</pre><HR></BLOCKQUOTE><br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6788827</guid>
<pubDate>Thu, 08 May 2003 14:35:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6756088</link>
<description><![CDATA[<A HREF="/useremail/u/432424"><b>MrH</b></A> : when installing gentoo(www.gentoo.org) besure to read ALL the directions :)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6756088</guid>
<pubDate>Mon, 05 May 2003 02:05:35 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6747283</link>
<description><![CDATA[<A HREF="/useremail/u/252734"><b>shdesigns</b></A> : Man page shows the command as part if X (XFree86)<br><br>Worked on RH8, 752 colors.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6747283</guid>
<pubDate>Sun, 04 May 2003 01:40:22 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6746685</link>
<description><![CDATA[<A HREF="/useremail/u/658117"><b>revrus</b></A> : Works on Suse 8.1 long list the 100 shades of grey kind of surprised me.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6746685</guid>
<pubDate>Sun, 04 May 2003 00:06:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6741693</link>
<description><![CDATA[<A HREF="/useremail/u/281766"><b>Mospaw</b></A> :  <BLOCKQUOTE><SMALL>said by  sago <A HREF="/useremail/u/542842"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>I can't vouch for Linux, ...typing ... showrgb ... gives you a list of colors that are available on your system.<HR></BLOCKQUOTE>I tried it on my local file server, a fairly sparse SuSE 8.0 installation (no GUI) as well as my public web server (SuSE 8.0, a few more services, but still no GUI), and the showrgb didn't work. It did, however, work on my local web server (SuSE 8.0) which has KDE (and a lot more stuff) installed.<br><br>it was a really long list. :)<br><small>--<br>My life is a continual parody of my life.<BR>--</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6741693</guid>
<pubDate>Sat, 03 May 2003 12:55:40 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6739887</link>
<description><![CDATA[<A HREF="/useremail/u/542842"><b>sago</b></A> : I can't vouch for Linux, (haven't tried it on Linux) - but on I can vouch for Solaris and FreeBSD - <br><br>           typing<br><br>bash-2.05$ showrgb<br><br>this gives you a list of colors that are available on your system - for instance if you want to start up an xterm in a different foreground and/or background color, or set the color of your window frames (in fvwm2, for instance).<br><br>Still need to find a good way to create a way of previewing the color...]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6739887</guid>
<pubDate>Sat, 03 May 2003 05:41:47 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6731999</link>
<description><![CDATA[<A HREF="/useremail/u/590475"><b>bleatingedge</b></A> : If I would have read to the end of this thread before replying, I would have noticed how unnecessary it was.<br><br>D'oh!<br><br>Michael<br><small>--<br>DirecWay SRS | Satmex5 | 1230 | GW: 66.82.158.16 | Win2K Host | 8 XP/Linux/Solaris Clients | Wireless LAN</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6731999</guid>
<pubDate>Fri, 02 May 2003 12:01:56 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6731958</link>
<description><![CDATA[<A HREF="/useremail/u/590475"><b>bleatingedge</b></A> :  <BLOCKQUOTE><SMALL>said by  AITechSE <A HREF="/useremail/u/735506"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Lose a file on your file system? Or want to find every file with <I>foo</I> in it?  Try this as root in /:<br><br>find .. | grep <I>foo</I><br><HR></BLOCKQUOTE><br><br>That will find every file with 'foo' in the name. One thing that I usually do if I want to find files that *contain* 'foo' is something like this:<br><br>find .  -type f | xargs grep foo<br><br>Narrowing it down to only files speeds things up a bit. It's been my experience that xargs is always faster than the exec function of find because it only spawns one process, where exec spawns one for every file found.<br><br>YMMV<br><br>Michael<br><small>--<br>DirecWay SRS | Satmex5 | 1230 | GW: 66.82.158.16 | Win2K Host | 8 XP/Linux/Solaris Clients | Wireless LAN</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6731958</guid>
<pubDate>Fri, 02 May 2003 11:57:12 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6730008</link>
<description><![CDATA[<A HREF="/useremail/u/542842"><b>sago</b></A> : Alternate ways of using your bash shell <br><br>by typing "history" at the command prompt you will the last commands you have entered (the number and types of commands saved in your command history can be adjusted). <br><br>By using the "!" exclamation point, you can select that command and re-run it. <br><br>Here I am manually opening the seti@home client in my home directory. <br><br>bash-2.05$ cd seti<br>bash-2.05$ ls<br>bash-2.05$ cd seti-3.03.i386-unknown-freebsd2.2.8<br>bash-2.05$ ./setiathome -verbose<br><br>in my history file this will generate (after one failed attempt because of an extra dash)<br><br>502  cd seti/<br>503  ls<br>504  cd setiathome-3.03.i386-unknown-freebsd2.2.8<br>505  ls<br>506  ./setiathome --verbose<br>507  ./setiathome -verbose<br><br>now... <br><br>bash-2.05$ !502; !504; !507<br><br>does the same thing as <br><br>bash-2.05$ cd seti; cdsetiathome-3.03.i386-unknown-freebsd2.2.8; ./setiathome -verbose<br> <br>this is what it looks like in the history now... <br><br>508  history<br>509  cd <br>510  cd seti/; cd setiathome-3.03.i386-unknown-freebsd2.2.8; ./setiathome -verbose<br>511  history<br><br>now... look for a pattern in the command line you want to execute<br><br>bash-2.05$  !?verb?<br><br>	surround that part with question marks<br><br>512  cd seti/; cd setiathome-3.03.i386-unknown-freebsd2.2.8; ./setiathome -verbose<br>513  history<br><br>does the same thing. <br><br>Actually, the bash shell has two modes - vi and emacs.  Imagine each of your previous commands as lines in an emacs or vi file (vi is the default mode).  You can move from line to line, edit the lines, change a letter or two, press enter as you wish. (although you only see one line at a time at your prompt).  You can also set how many lines of history you want to have, or save certain types (or only certain types) of commands. <br><br>There is much much more, as well. It can get pretty confusing, but I do recommend reading "man bash" if you have the time sometime. It's interesting, to say the least. <br><br>Of course it's just much easier to create a shell script, but bash is pretty cool when you look a little deeper into it. ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6730008</guid>
<pubDate>Fri, 02 May 2003 05:56:15 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6729452</link>
<description><![CDATA[<A HREF="/useremail/u/806220"><b>Sens Rule</b></A> : For those of us who can't type.. I like the following for removing files with weird name like '* holycow&'<br><br>rm -i -- *<br><br>It will list each file and ask if you want to delete it..]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6729452</guid>
<pubDate>Fri, 02 May 2003 01:59:33 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6726529</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : Here is a tip someone in this very forum gave me. If you ever want to remotely log in, execute a script and logout with the script running and not terminating it (as long as the script continues running) simply start the script using 'nohup'.<br><BLOCKQUOTE>code:<HR><pre>$nohup scriptname.sh &</pre><HR></BLOCKQUOTE><br>This is something that I have found very valuable. Thanx to whomever provided me that answer!]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6726529</guid>
<pubDate>Thu, 01 May 2003 20:00:27 EDT</pubDate>
</item>

<item>
<title>Re: Semicolon Madness II...</title>
<link>http://www.dslreports.com/forum/remark,6672689</link>
<description><![CDATA[<A HREF="/useremail/u/656330"><b>stefaanE</b></A> :  <BLOCKQUOTE><SMALL>said by  nixen <A HREF="/useremail/u/698757"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Dude... what's the bit with being <TT>exec</TT> happy on your find statements? ;) <HR></BLOCKQUOTE> You might have noticed I was explaining the reason for the semicolon and the associated escape, not how to use "find" in a system-friendly way. <br>The point is well taken though - but in my 25 years of Unix (I learned the trade on the 7th Edition), I've never had a system choke on <TT>fork/execs</TT> generated by (even a very ill-conceived) find command. <br><br>Talking about system load, the most remarkable case of sluggishness I encountered was caused by Oracle appending, on each transaction, a couple of bytes to a log file that had grown to several hundreds of megabytes. The DBAs had experience with Oracle 8, and didn't realise that on an instance Oracle 7 running on the system (a Sun Enterprise 5000 if memory serves) logging was turned <B>on</B> by default (Oracle changed it to off for 8). No-one understood why the legacy system using Oracle 7 was running in treacle until I had the idea to truss the process - opening the log file, appending a few bytes and closing it took several <B>seconds</B>... <br><br>Take care,<br><br>Stefaan<br><small>--<br>"Technically, Windows is an 'operating system,' which means that it supplies your computer with the basic commands that it needs to suddenly, with no warning whatsoever, stop operating." -Dave Barry </small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6672689</guid>
<pubDate>Sat, 26 Apr 2003 05:03:19 EDT</pubDate>
</item>

<item>
<title>Re: Semicolon Madness II...</title>
<link>http://www.dslreports.com/forum/remark,6670852</link>
<description><![CDATA[<A HREF="/useremail/u/698757"><b>nixen</b></A> : Dude... what's the bit with being <TT>exec</TT> happy on your find statements? ;)<br><br>Remember, each time you get a match that causes an <TT>exec</TT>, you fork off a process. If you only have a few matches, fine. However, if you have a bunch of them, you are going to <I>KILL</I> your system. For example, with your <TT>find . -type f -exec rm -f {} \; -print</TT>, given 1000 matches, you do 1000 <TT>exec</TT>'s/processes. If you, instead, rewrite that as <TT>find . -type f -print | xargs rm</TT>, you might spawn off 4-5 extra processes beyond the basic <TT>find</TT>. That's a <I>lot</I> friendlier to your system.<br><br>-tom<br><small>--<br>You can be only -so- accurate with a sledgehammer.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6670852</guid>
<pubDate>Fri, 25 Apr 2003 22:52:02 EDT</pubDate>
</item>

<item>
<title>Re: Semicolon Madness II...</title>
<link>http://www.dslreports.com/forum/remark,6666282</link>
<description><![CDATA[<A HREF="/useremail/u/656330"><b>stefaanE</b></A> :  <BLOCKQUOTE><SMALL>said by  Daniel <A HREF="/useremail/u/168087"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL>said by  stefaanE <A HREF="/useremail/u/656330"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Thus, you have to escape them to protect them from being interpreted by the shell, and passed to "find" as positional parameters instead.<HR></BLOCKQUOTE>Ok, so you are saying that a semicolon is needed in order to do the command correctly, but that if you don't escape it, it will be seen as an end to the <I>entire</I> command (like in c)?  <HR></BLOCKQUOTE> Correct - it would be the end of one shell statement, and the remaining words would no longer be part of the parameters passed to the find command.<br> <BLOCKQUOTE><SMALL>said by  Daniel <A HREF="/useremail/u/168087"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>That makes sense.  So the semicolon (when escaped) is actually similar to a pipe in this case, right?  Sort of like a continuation to the next command.  Otherwise, why not just omit the semicolon altogether?  You wouldn't have to escape something that wasn't there, so it must be being used as a transition from one command to another, right? <HR></BLOCKQUOTE> It's not like a pipe - that's again a shell metacharacter, and it means something akin to the semicolon ("end the command and pipe the standard output into the standard input of the command after the pipe, run both of them concurrently", versus "end the command and start a new one after the first has finished"). <br>The semicolon must be escaped because it is interpreted by the "find" command. You can't omit it because otherwise "find" cannot determine when your -exec ends (remember that the commands introduced by exec can have - options:<br><TT><br>$ find . -type f -exec rm -f {} \; -print<br></TT><br>As you can see, you need a special character to tell find that the command started by -exec is finished. <br><br>That being said, "find" could have been designed differently, but it has its own logic nonetheless.<br><br>Take care,<br><br>Stefaan<br><small>--<br>"Technically, Windows is an 'operating system,' which means that it supplies your computer with the basic commands that it needs to suddenly, with no warning whatsoever, stop operating." -Dave Barry </small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6666282</guid>
<pubDate>Fri, 25 Apr 2003 13:48:14 EDT</pubDate>
</item>

<item>
<title>Re: Semicolon Madness II...</title>
<link>http://www.dslreports.com/forum/remark,6665473</link>
<description><![CDATA[<A HREF="/useremail/u/168087"><b>Daniel</b></A> :  <BLOCKQUOTE><SMALL>said by  stefaanE <A HREF="/useremail/u/656330"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Semicolons are special to the shell, they terminate a statement just like the end-of-line.<HR></BLOCKQUOTE>Right, this is what I understood.<br><br> <BLOCKQUOTE><SMALL>said by  stefaanE <A HREF="/useremail/u/656330"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Thus, you have to escape them to protect them from being interpreted by the shell, and passed to "find" as positional parameters instead.<HR></BLOCKQUOTE>Ok, so you are saying that a semicolon is needed in order to do the command correctly, but that if you don't escape it, it will be seen as an end to the <I>entire</I> command (like in c)? <br><br>That makes sense.  So the semicolon (when escaped) is actually similar to a pipe in this case, right?  Sort of like a continuation to the next command.  Otherwise, why not just omit the semicolon altogether?  You wouldn't have to escape something that wasn't there, so it must be being used as a transition from one command to another, right?<br><SMALL>--<br>"Opportunities multiply as they are seized." - Sun Tzu</SMALL><br><i>[text was edited by author 2003-04-25 12:26:51]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6665473</guid>
<pubDate>Fri, 25 Apr 2003 12:23:48 EDT</pubDate>
</item>

<item>
<title>Re: Semicolon Madness...</title>
<link>http://www.dslreports.com/forum/remark,6663004</link>
<description><![CDATA[<A HREF="/useremail/u/656330"><b>stefaanE</b></A> :  <BLOCKQUOTE><SMALL>said by  Daniel <A HREF="/useremail/u/168087"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL>said by  stefaanE <A HREF="/useremail/u/656330"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>$ find /home \( -exec grep TEST {} \; -o -user "me" \) -exec rm {} \;</TT><br><HR></BLOCKQUOTE>Ok, sounds great.  I am iffy, however, on the whole use of the escaped semicolon.  How does that work?<br> <HR></BLOCKQUOTE>Semicolons are special to the shell, they terminate a statement just like the end-of-line, which is why<br><SMALL><TT><br>if [ -z "$a" ]<br>then<br></TT></SMALL><br>is the same as<br><SMALL><TT><br>if [ -z "$a" ] ; then<br></TT></SMALL><br>Thus, you have to escape them to protect them from being interpreted by the shell, and passed to "find" as positional parameters instead. "find" considers the parameters between the -exec (or -ok) and the semicolon as one expression returning either TRUE or FALSE. When an expression evaluates to FALSE, "find" moves to the next file, otherwise it evaluates the next expression. In the example above, <B>if</B> the file contains the word "TEST" <B>or</B> is owned by "me", <B>then</B> it is deleted. Again, the parentheses are special to the shell and need to be protected by either a backslash or by putting them in quotes. <br><br>Take care,<br><br>Stefaan<br><small>--<br>"Technically, Windows is an 'operating system,' which means that it supplies your computer with the basic commands that it needs to suddenly, with no warning whatsoever, stop operating." -Dave Barry </small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6663004</guid>
<pubDate>Fri, 25 Apr 2003 03:15:52 EDT</pubDate>
</item>

<item>
<title>Semicolon Madness...</title>
<link>http://www.dslreports.com/forum/remark,6658967</link>
<description><![CDATA[<A HREF="/useremail/u/168087"><b>Daniel</b></A> :  <BLOCKQUOTE><SMALL>said by  stefaanE <A HREF="/useremail/u/656330"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>$ find /home \( -exec grep TEST {} \; -o -user "me" \) -exec rm {} \;</TT><br><HR></BLOCKQUOTE>Ok, sounds great.  I am iffy, however, on the whole use of the escaped semicolon.  How does that work?<br><small>--<br>"Opportunities multiply as they are seized." - Sun Tzu</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6658967</guid>
<pubDate>Thu, 24 Apr 2003 18:24:10 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6657165</link>
<description><![CDATA[<A HREF="/useremail/u/450098"><b>elboricua</b></A> : Wow loads of good info here.  I am surprised that no one mentioned tac.  I use it alot. tac works just like cat only reveresed hence the name tac.<br><br>Here is an example.<br><br><BLOCKQUOTE>code:<HR><PRE>cat somefile<br>testing<br>this<br>out<br>to<br>see<br>how<br>cat<br>and<br>tac<br>work</PRE><HR></BLOCKQUOTE><br><br>If we use tac it will show the file in reverse order.<br><br><BLOCKQUOTE>code:<HR><pre>tac somefile<br>work<br>tac<br>and<br>cat<br>how<br>see<br>to<br>out<br>this<br>testing</pre><HR></BLOCKQUOTE><br><SMALL>--<br>Si te quieres divertir,<br>con encanto y con primor <br>s&oacute;lo tienes que vivir, <A HREF="http://www.broadbandreports.com/forum/remark,4071839~root=journals~mode=flat">Un Verano En Nueva York</A>.</SMALL><br><br><i>[text was edited by author 2003-04-24 18:58:09]</i>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6657165</guid>
<pubDate>Thu, 24 Apr 2003 14:55:17 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6654649</link>
<description><![CDATA[<A HREF="/useremail/u/698757"><b>nixen</b></A> : If you have a Solaris system that you want to do a quick disk inventory on:<br><PRE><br>   (iostat -En ; echo) | sed '{<br>      s/ *Soft.*$//<br>      s/ *Revision.*$//<br>      s/ *Product: / /<br>      s/ &lt;.*$//<br>      s/^Vendor/   &/<br>      s/^Size/   &/<br>      /^Media/d<br>      /^Illegal/d<br>      }' | sed '{<br>      /Size/{N<br>      s/\n/&&/<br>      }<br>   }'<br></PRE><br>You may want to run <TT>devfsadm</TT>, first, to make sure that all drives that the OS can query are actually in the hardware graph.<br><br>-tom<br><small>--<br>You can be only -so- accurate with a sledgehammer.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6654649</guid>
<pubDate>Thu, 24 Apr 2003 09:28:39 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6653145</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> : I know.  I knew about `killall' before I knew about `kill', but /sbin/pidof is pretty nifty too :D]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6653145</guid>
<pubDate>Thu, 24 Apr 2003 00:19:43 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6650817</link>
<description><![CDATA[<A HREF="/useremail/u/423938"><b>davidsmind</b></A> :  <BLOCKQUOTE><SMALL>said by  ftzsee <A HREF="/useremail/u/520788"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>/sbin/pidof [process name] prints the PID of the process.  This is useful for <TT>kill -9 `/sbin/pidof whatever`</TT><HR></BLOCKQUOTE><br><br>The killall command works just the same as this, example:<br><br>killall smbd<br><br>or to be harsh:<br><br>killall -9 smbd<br><br>Ta Da!<br><small>--<br> "Unix is the most user friendly system I know, it's just picky about who it considers a friend."</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6650817</guid>
<pubDate>Wed, 23 Apr 2003 20:21:13 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6618714</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> : here is one that mite interest people. To loose the redhat logo for the start main menu in RH8 and RH9 and make the foot global across the themes the fast easy way, or any icon you choose. <br><br>Get a Gnome Foot icon .png. Rename it redhat-main-menu.png and cp it to /usr/share/pixmaps copying over the RedHat logo.<br><small>--<br><A HREF="http://www-1.ibm.com/servers/eserver/linux/fun/freethecode.html"><B>Free The Code</A></B>, but remember there is a world outside. Stepping away from the box will help you solve the answers you seek. Anger blocks thought.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6618714</guid>
<pubDate>Sun, 20 Apr 2003 10:27:15 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6615216</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> : More fun:<br><br>/sbin/pidof [process name] prints the PID of the process.  This is useful for <TT>kill -9 `/sbin/pidof whatever`</TT><br><br>If you edit your ~/.bashrc or /etc/profile, you don't have to reboot / close your terminal for the changes to take effect.  Just type <TT>source ~/.bashrc</TT> or <TT>source /etc/profile</TT><br><br>Typing <TT>wget http: //web/path/to/a/file.tar.gz</TT>, the file will be downloaded to the directory you are in.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6615216</guid>
<pubDate>Sat, 19 Apr 2003 20:18:15 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6614607</link>
<description><![CDATA[<A HREF="/useremail/u/423938"><b>davidsmind</b></A> : Typing 'cd' and 'cd' alone will bring you back to your home directory.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6614607</guid>
<pubDate>Sat, 19 Apr 2003 18:38:42 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6607120</link>
<description><![CDATA[<A HREF="/useremail/u/520788"><b>ftzsee</b></A> : When is this topic coming off sticky?<br><br><TT>$ cd -</TT> will put you in the directory you were last in.  I use this a lot.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6607120</guid>
<pubDate>Fri, 18 Apr 2003 19:54:00 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6544070</link>
<description><![CDATA[<A HREF="/useremail/u/656330"><b>stefaanE</b></A> : find is remarkably powerful:<br><br>To find and remove all the files with "TEST" in them:<TT><br>$ find ~ -exec grep TEST {} \; -exec rm {} \;<br></TT><br>If you want a prompt before the command is executed, replace<br>-exec with -ok:<TT><br>$ find ~ -exec grep SPAM {} \; -ok mv {} /var/tmp/SPAM \;<br></TT><br>One can also group "find" expressions:<br><TT><br>$ find /home \( -exec grep TEST {} \; -o -user "me" \) -exec rm {} \;</TT><br>will delete all the files that contain TEST or belong to user "me".<br><br>Take care,<br><small>--<br>"Technically, Windows is an 'operating system,' which means that it supplies your computer with the basic commands that it needs to suddenly, with no warning whatsoever, stop operating." -Dave Barry </small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6544070</guid>
<pubDate>Fri, 11 Apr 2003 17:49:44 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6535243</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> : I use "which" and "what" almost daily. "which" will tell you where in your PATH a binary is.  "what" will tell you some things about how that binary was compiled. E.g.,<BLOCKQUOTE>code:<HR><pre>bash-2.04$ which telnet<br>/usr/bin/telnet<br>bash-2.04$ what /usr/bin/telnet<br>/usr/bin/telnet:<br>	commands.c	8.4 (Berkeley) 5/30/95<br>	 Copyright (c) 1988, 1990, 1993<br>	main.c	8.3 (Berkeley) 5/30/95<br>	kerberos.c	8.3 (Berkeley) 5/30/95<br>	auth.c	8.3 (Berkeley) 5/30/95<br>	enc_des.c	8.3 (Berkeley) 5/30/95<br></pre><HR></BLOCKQUOTE><br><br>"what" doesn't appear to exist on Linux (tried Redhat 7.3 and Gentoo.)  It exists on most other Unices (I've used it on Tru64, AIX, and HP-UX.)  It may not be in your PATH on Solaris (/usr/ccs/bin/what.)<br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6535243</guid>
<pubDate>Thu, 10 Apr 2003 18:36:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6472706</link>
<description><![CDATA[<A HREF="/useremail/u/165137"><b>Drunkula</b></A> : Okay we slowed down so I'll post another.  I'm not sure if this was covered already but...<br><br>Temporarily change the runlevel at boot time in Linux:<br>1.  If you use Grub as the bootloader highlight the Linux kernel you want to boot and just add the number of the runlevel you wish to boot after the respective command.  Be sure there is a space between the runlevel and the other parameters.<br><br>2. If you use LILO as a boot loader hit the TAB key to bring up the boot list.  Select the one you want boot by typing it's name followed by the runlevel number.  (example linux 3)<br><br>If your default boot is to runlevel 5 this is a quick and easy way to change to textmode or single user or whatever.  Check your distro docs for the different runlevel uses....<br><SMALL>--<br>Real patriots don't criticize their President!<br>&raquo;<A HREF="http://www.drunkula.net:5517/" >www.drunkula.net:5517/</A></SMALL><br><i>[text was edited by author 2003-04-03 19:28:59]</i>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6472706</guid>
<pubDate>Thu, 03 Apr 2003 19:10:23 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6451789</link>
<description><![CDATA[<A HREF="/useremail/u/238716"><b>Smitedogg</b></A> : To run some shell commands while doing a vi edit session enter ":", then enter "shell".<br><br>This suspends the vi session and gives you a command prompt where you can use any shell command. When finished, enter the "exit" command and you will be returned to the vi session. <br><br>Dogg<br><small>--<br>Religion is what keeps the poor from murdering the rich. --Napoleon</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6451789</guid>
<pubDate>Tue, 01 Apr 2003 17:42:55 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6409191</link>
<description><![CDATA[<A HREF="/useremail/u/585967"><b>jknowler</b></A> : [RedHat/bash] !Be careful with this one! I found this to be helpful and time saving when getting rid of old kernels and lib module files. Go to the directory where your boot kernel files live. I keep mine in /boot. Enter "rm *xx-yy*" (don't enter the quotes)  where xx-yy is the kernel version you want to remove.  I keep confirm set "ON" so it asks me to delete each file, a safety precaution just in case things go hay-wire :) MAKE SURE IT'S DELETING WHAT YOU WANT! and say "Y" for each file.  Move to the /lib/modules directory and do the same thing. In summation: the file mask character "*" can be used multiple times and where ever you need in the file spec. <br><small>--<br>EL SRS DAK403_P8, SM 5/990, GW 144, Proxomitron Proxy On, Dual PII 350's, w/256M Ram, XP Pro & ICS, RH & XP clients</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6409191</guid>
<pubDate>Fri, 28 Mar 2003 01:01:02 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6386442</link>
<description><![CDATA[<A HREF="/useremail/u/762593"><b>lokem</b></A> : Since there are a couple posts regarding the "find" command, here's an additional one to it ;)  If there's a need to do something to the result of the "find" command, here's how to do it:<br><br>find . -name 'core' -exec rm {} \;<br><br>The {} string represents the current file name.  While \; is a way to end the -exec param.  The semicolon needs to be escaped.<br><br>Hope this helps!]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6386442</guid>
<pubDate>Tue, 25 Mar 2003 21:01:55 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6386197</link>
<description><![CDATA[<A HREF="/useremail/u/762593"><b>lokem</b></A> : If you'd like to know who has logged in previously, try the "last" command.  You could also use the "lastb" command which also shows the bad login attempts.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6386197</guid>
<pubDate>Tue, 25 Mar 2003 20:41:51 EDT</pubDate>
</item>

<item>
<title>more VIM tricks</title>
<link>http://www.dslreports.com/forum/remark,6371633</link>
<description><![CDATA[<A HREF="/useremail/u/241784"><b>tomkb</b></A> : The following makes vim SO much easier to use.  You can use the arrow keys, delete key, as well as backspace keys much easier, more like a regular editor.  It's very simple, do the following.<br><br>In your home directory (most likely /root), create the following invisible file with vim. <br><br>vim /root/.vimrc<br><br>(The period in front makes it invisible)<br><br>Add the following 2 lines to the file and save the file with the normal :wq<br><br>set nocompatible<br>set bs=2<br><br>That's it!  You will be pleasantly surprised with the ease of use next time you use vim.<br><small>--<br>clenetworks.net</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6371633</guid>
<pubDate>Mon, 24 Mar 2003 11:44:02 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6337838</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> : <B>favicon.ico</B> Making one for your WebSite on your  *NIX workstation<br><br>You know, that cool little icon in your URL field in your browser.<br><br>.ico is a MS icon file so you need to convert it. How you say and with what.<br><br>With the Gimp and png2ico.<br><br>You create the image with the Gimp and save as a .png then convert it with png2ico.<br><br><B>png2ico</B><br>&raquo;<A HREF="http://www.winterdrache.de/freeware/png2ico/index.html" >www.winterdrache.de/freeware/png&middot;&middot;&middot;dex.html</A><br><br><I>Try to keep the number of colors below 16 and create a 16-color icon using the --colors 16 switch of png2ico (or even create a b/w icon with the --colors 2 switch). This will result in a smaller file that loads faster. </I><br><br>The short of it is, a favicon.ico is 16x16 pix and 16 color,this is most common, but some browsers support 32 colors.<br><br>Then adding a "link rel=" html tags in the head of your pages.<br><br>link rel="icon" href="favicon.ico" type="image/x-icon"<br><br>link rel="shortcut icon" href="favicon.ico" type="image/x-icon"<br><br>This link is a good HOWTO:<br>&raquo;<A HREF="http://www.winterdrache.de/freeware/png2ico/favicon.html" >www.winterdrache.de/freeware/png&middot;&middot;&middot;con.html</A><br><br>This would be a good webmonks tip, but I figured that a lot of people new to *nix are coming to set up web services and mostly Web. Also how to do it on a *Nix box. <br><br> <br><small>--<br><A HREF="http://www-1.ibm.com/servers/eserver/linux/fun/freethecode.html"><B>Free The Code</A></B>, but remember there is a world outside. Stepping away from the box will help you solve the answers you seek. Anger blocks thought.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6337838</guid>
<pubDate>Thu, 20 Mar 2003 15:53:01 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6325155</link>
<description><![CDATA[<A HREF="/useremail/u/698757"><b>nixen</b></A> : ${HOME}/.ssh/ssh_config can make your life a bit easier. You can use that file to specify different behaviors by hostname, etc. Read the man pages for ssh_config. It's pretty slick.<br><br>-tom<br><small>--<br>You can be only -so- accurate with a sledgehammer.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6325155</guid>
<pubDate>Wed, 19 Mar 2003 10:37:02 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6324702</link>
<description><![CDATA[<A HREF="/useremail/u/704973"><b>elluzion</b></A> : This was new to me today...<br><br>Your system probably has a default web browser that gets launched automatically whenever some html needs to be viewed or a link is clicked or whatever. However, you may want to change the system's default browser. Or, you may want your account to use a different broswer than the rest of the system's accounts.<br><br>In the first case, changing the system's overall default browser, you do this by editing or creating a file named /etc/htmlview.conf using the following format...<br><br>X11BROWSER=&lt;path to browser&gt;<br><br>So, for instance...<br><br>X11BROWSER=/usr/local/mozilla/mozilla<br><br>In the second case, you can set a different browser for just your account by editing or creating a file named ~/.htmlviewrc using the same format as above.<br><i>[text was edited by author 2003-03-19 09:28:14]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6324702</guid>
<pubDate>Wed, 19 Mar 2003 09:27:16 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6322918</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> : This was a big "duh" for me.  I found myself compiling lots of kernels for my old laptop in trying to get the PCMCIA stuff to work properly.  Problem was it took <I>forever</I> for them to compile on the wheezy Pentium I 266 CPU it has.<br><br>It dawned on me I could compile the kernels on my desktop system and just scp them over...<br><br>Better still, my desktop has enough disk space that I can keep lots of different kernel source trees on it.  So I could be fiddling with 2.4.19 on the laptop while my desktop crunched away at compiling 2.4.20.<br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6322918</guid>
<pubDate>Wed, 19 Mar 2003 00:31:29 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6322387</link>
<description><![CDATA[<A HREF="/useremail/u/465004"><b>ironwalker</b></A> : clock on the top of your terminal: Edit the profile file, vi /etc/profile and add the following line: PROMPT_COMMAND='echo -ne "\0337\033[2;999r\033[1;1H\033[00;44m\033[K"`date`"\033[00m\0338"'<br><br> <br>The result will look like: <br><small>--<br>"LIVE FREE OR DIE"www.Theforumz.com</small><div class="borderless"><TABLE WIDTH=95% align=center border=0 CELLPADDING=4"><TR><TD ALIGN=CENTER VALIGN=CENTER BGCOLOR=#000000 nwrap COLSPAN=3 WIDTH=100%><A HREF="/speak/slideshow/6322387?c=312368&ret=L2ZvcnVtL3I2MTc4MDA4LnhtbA%3D%3D"><IMG TITLE="9471 bytes" BORDER=0 WIDTH=500 HEIGHT=256 SRC="/r0/download/312368~a3bfeb51e0fd33e3dc782cb5b6a6e1de/time01.gif"></A></TD></TABLE></div>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6322387</guid>
<pubDate>Tue, 18 Mar 2003 23:30:18 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6315447</link>
<description><![CDATA[<A HREF="/useremail/u/537853"><b>cangeceiro</b></A> : "man tuning" gives some tips how to tune performance of your FreeBSD system<br><small>--<br>Bang Bang Bang your head(on the desk)</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6315447</guid>
<pubDate>Tue, 18 Mar 2003 12:11:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6308960</link>
<description><![CDATA[<A HREF="/useremail/u/714753"><b>movement3</b></A> : These commands have been helpful to me:<br><br><B>Secure Copy through SSH:</B><br><br>This is handy if you need to copy a file through an encrypted tunnel on one system to another when the file is not under the web or FTP directory.<br><br>scp [filename] [remote host address]:/path/remote/computer<br><br>scp some_filename bob@domain.com:/home/bob/<br>or<br>scp some_filename bob@111.111.111.111:/home/bob/<br><br><B>Screen:</B><br><br>Have multiple screens open rather than having several putty sessions open on your desktop. You can also open a screen session, run a process, close putty and the process will continue.<br><br>screen to start a screen session<br>Ctrl-a (press Ctrl and a at the same time) n to scroll through your different screens if you have more than one.<br>Ctrl-a d to detached from your screen, and regular to your regular terminal.<br>screen &#150;r to resume a running screen session<br><br><B>chattr and lsattr:</B><br><br>One time I wanted to delete a filename but it had chattr +i filename on it, without issuing chattr &#150;i you cannot delete or chmod the file. lsattr filename to see what attributes it currently has.<br><br><B>strace:</B><br><br>When you do a top and see a process is taking up the CPU percentage, but you do not know where it&#146;s coming from. Strace will give you a verbose detail output of what the particular process is doing; it can provide clues for troubleshooting.<br><br>strace -s 1000 -fxtvo /root/output -p [Process ID]<br><br>With these flags, the results of strace will be sent to /root/output. ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6308960</guid>
<pubDate>Mon, 17 Mar 2003 19:23:14 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6298674</link>
<description><![CDATA[<A HREF="/useremail/u/182682"><b>Gigantopithi</b></A> : Use distcc to compile across several hosts.  Great for compiling xfree86, kde, gnome.  Saves loads of time and is very efficient if done on a lan.<br><small>--<br>Do you think that's air you're breathing?</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6298674</guid>
<pubDate>Sun, 16 Mar 2003 18:45:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6296421</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> :  <BLOCKQUOTE><SMALL>said by  jknowler <A HREF="/useremail/u/585967"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>I have not seen anything about "filename completion".  Key part of the filename and hit the TAB key...<HR></BLOCKQUOTE>This works by default in bash.  There are ways to do it in the other shells, but I've never researched it, 'cause I almost always use bash.<br><br>BTW, did you know you can configure Windows to do this too?<br><br>&raquo;<A HREF="http://www.microsoft.com/windows2000/techenthusiast/tricks/customization/completion.asp" >www.microsoft.com/windows2000/te&middot;&middot;&middot;tion.asp</A><br>&raquo;<A HREF="http://www.fuzzygroup.com/writing/windowstabcompletion.htm" >www.fuzzygroup.com/writing/windo&middot;&middot;&middot;tion.htm</A><br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6296421</guid>
<pubDate>Sun, 16 Mar 2003 14:07:43 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6288370</link>
<description><![CDATA[<A HREF="/useremail/u/157667"><b>peterr</b></A> : Here's my fave:<br><br>When faced with deleting a file containing weird characters (especially the previously mentioned file starting with "-"), I use the "unlink" command which does not process any switches.  This lives in /usr/sbin for linux.<br><br>/usr/sbin/unlink -stupid_file_name<br><br>/P]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6288370</guid>
<pubDate>Sat, 15 Mar 2003 15:22:13 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6284731</link>
<description><![CDATA[<A HREF="/useremail/u/372465"><b>Skipdawg</b></A> : I love this online tool for finding RPM's &raquo;<A HREF="http://www.rpmfind.net" >www.rpmfind.net</A> ;)<br><small>--<br><B>Proud US Navy Veteran.</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6284731</guid>
<pubDate>Sat, 15 Mar 2003 03:10:34 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6283654</link>
<description><![CDATA[<A HREF="/useremail/u/570732"><b>bgrundy</b></A> : Watching a file "grow"...<br><br>If I'm moving a large file across a network (piped through rsh or ssh), or dd'ing a large file (disk image, etc.) I cat watch the progress with the "watch" command.  Basically, it runs the same command over and over again (every 2 seconds by default).<br><br>for example, watching the progress of a 2 GB dd image:<br>-issue the dd command<br>-switch to another terminal<br>-"watch ls -lh"<br>-the "ls" output is updated every two seconds...Progress is now visible.<br> <br> <br><small>--<br>"If you continue to use Windows, your system may become unstable"  --BSOD</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6283654</guid>
<pubDate>Fri, 14 Mar 2003 23:55:02 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6281589</link>
<description><![CDATA[<A HREF="/useremail/u/585967"><b>jknowler</b></A> : I have not seen anything about "filename completion".  Key part of the filename and hit the TAB key.  Works for directories to!  I have worn out more TAB keys on my keyboards.  Also, Hit the up and down arrow keys to scroll up and down through previously entered command lines. Once you find the command you want, hit the forward/back arrow keys, make corrections and hit ENTER.  *whoosh*  :)<br><br>Edit:I almost forgot, on "filename completion" hit TAB twice to get a listing of possibilities.  This is helpful you get lost in a long directory path.<br><SMALL>--<br>EL SRS DAK403_P5, SatMex 5/990, GW 144, Proxy Off, RWin 474280, MTU 1500, Dual PII 350's, w/256M Ram, XP Pro w/ICS, RedHat & XP clients</SMALL><br><I>[text was edited by author 2003-03-14 20:35:41]</I><br><br><i>[text was edited by author 2003-03-14 20:37:12]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6281589</guid>
<pubDate>Fri, 14 Mar 2003 20:32:20 EDT</pubDate>
</item>

<item>
<title>SSH performance tuning.. I guess</title>
<link>http://www.dslreports.com/forum/remark,6271773</link>
<description><![CDATA[<A HREF="/useremail/u/751036"><b>a_use_r</b></A> : Want to speed up login time with ssh?<br><br>vi /(ssh_base)/etc/ssh_prng_cmds<br><br>Remove all commands that don't apply to your particular system/os.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6271773</guid>
<pubDate>Thu, 13 Mar 2003 20:51:17 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6271592</link>
<description><![CDATA[<A HREF="/useremail/u/782124"><b>BeesTea</b></A> : Mojosan,<br><br>You can just take advantage of shell expansion and accomplish the same thing.<br><br>ps -ax | grep [f]oo<br><br>will return only procesees named foo, the grep in the process table will not be included.<br><br>Cheers,<br>-BeesT]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6271592</guid>
<pubDate>Thu, 13 Mar 2003 20:31:45 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6263915</link>
<description><![CDATA[<A HREF="/useremail/u/692958"><b>soulburner</b></A> : I don't have much to lend, but it was kind of useful to me, so I'll pass it along.<br><br><BLOCKQUOTE>code:<HR><pre>apropos searches a set of database files containing short descriptions of<br>system commands for keywords and displays the result on the standard output.</pre><HR></BLOCKQUOTE><br><br>So, <B>apropos 'expression'</B> would find all commands that have <B>'expression'</B> in the name/description of the command.<br><br>&raquo;<A HREF="http://www.oreillynet.com/pub/au/73" >www.oreillynet.com/pub/au/73</A> has also helped me out with learning a few things about my FreeBSD box.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6263915</guid>
<pubDate>Thu, 13 Mar 2003 01:18:39 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6256165</link>
<description><![CDATA[<A HREF="/useremail/u/487980"><b>bbrkdub</b></A> :  <BLOCKQUOTE><SMALL>quote:</SMALL><HR>i think we should just jump onto the subject of how too root eachothers boxes so we can test all these cool little tricks<HR></BLOCKQUOTE><br><br>Let's don't and say we did :)<br><br>Here's another trick I found while reading and OpenBSD article awhile back. This script outputs the PID of a program, w/o the extra 'grep' PID process being displayed. I stripped a little bit of the documentation portion of my script header, so please excuse the mess.<br><br>#!/bin/sh<br>#<br># Prerequisite(s):<br>#  1) A basic understanding of shell programming.<br>#<br># Syntax:<br>#  pid [pattern]<br>#<br># Example(s):<br>#  pid root<br>#  pid sendmail<br>#<br><br>if [ $# != 1 ]<br>then<br>  echo "Usage: $0 [pattern]"<br>  exit 1<br>fi<br><br>ps -awwwwx | grep -v grep | grep $1<br><small>--<br>Hope this helps...</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6256165</guid>
<pubDate>Wed, 12 Mar 2003 12:16:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6255374</link>
<description><![CDATA[<A HREF="/useremail/u/432424"><b>MrH</b></A> : i think we should just jump onto the subject of how too root eachothers boxes so we can test all these cool little tricks :D<br><br>jp jp jp :D]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6255374</guid>
<pubDate>Wed, 12 Mar 2003 10:41:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6254627</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> : Hopefully I'll be able to use half of these some day.  ;)<br><small>--<br><I>Updated My Journal</I></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6254627</guid>
<pubDate>Wed, 12 Mar 2003 08:48:59 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6248604</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> :  <BLOCKQUOTE><SMALL>said by  Steve <A HREF="/useremail/u/340145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Yes, the numbers aren't hard to learn<HR></BLOCKQUOTE>Yeah, I thought so too except for the errors with the numbers in my original post :o<br><br>Thanks for  freerock <A HREF="/useremail/u/383145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> for pointing them out.<br><br> <BLOCKQUOTE><SMALL>said by  paul1238 <A HREF="/useremail/u/233421"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>rwx------ which represents three sets of bits where each group is made up of three bits. So the groups of bits from right to left describe the: OWNER, GROUP, and WORLD access permissions. Each of the three bits in a group represent READ, WRITE, EXECUTE from right to left.<HR></BLOCKQUOTE>That should be from left to right. <br> <BLOCKQUOTE><SMALL>said by  paul1238 <A HREF="/useremail/u/233421"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Two commonly used bits in the fourth group of bits are the the setuid bit which is 100 000 000 000 (4000 in octal) and the sticky bit which is 100 000 000 000 (1000 in octal).<HR></BLOCKQUOTE>Obviously, the numbers should not be the same. The sticky bit is 001 000 000 000 which is octal 1000.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6248604</guid>
<pubDate>Tue, 11 Mar 2003 18:00:04 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6247680</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : Im totally surprised by everyone's very helpful tips!<br>I had no idea of ANY of these tricks whatsoever. Or of the number of generous posts! Far more than I originally expected :) <br><br>I have been printing these posts since you guys started :)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6247680</guid>
<pubDate>Tue, 11 Mar 2003 16:39:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6246948</link>
<description><![CDATA[<A HREF="/useremail/u/168864"><b>sporkme</b></A> :  <BLOCKQUOTE><SMALL>said by  bbrkdub <A HREF="/useremail/u/487980"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br><B># cat ~/bin/scroll</B><br><PRE>#!/bin/sh<br>cat $@ | less</PRE><br> <HR></BLOCKQUOTE><br><br>Why not just "less filename"?<br><br>As to vi -R, usually "view" is a link that will do the same.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6246948</guid>
<pubDate>Tue, 11 Mar 2003 15:30:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6246357</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> :  <BLOCKQUOTE><SMALL>said by  Steve <A HREF="/useremail/u/340145"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>Yes, the numbers aren't hard to learn, but they are not <B>relative</B>.<HR></BLOCKQUOTE>That is a disadvantage to me.  I seldom want to set relative permissions on a bunch of files.  I often want to set absolute permissions on a single file.<br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6246357</guid>
<pubDate>Tue, 11 Mar 2003 14:26:45 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6245499</link>
<description><![CDATA[<A HREF="/useremail/u/487980"><b>bbrkdub</b></A> : Ok, I'll add another one. If you like cat(1) and less(1), then combine them to 'scroll' through your files. I use this little script for viewing a lot of my documentation without risking an accidental write from vi(1) (NOTE: I know about <B>vi -R</B>, but I like the way this script works).<br><br><B># cat ~/bin/scroll</B><br><PRE>#!/bin/sh<br>cat $@ | less</PRE><br><br>Then, I just add an alias to my ~/.bashrc file:<br><br><B>alias s='scroll'</B><br><small>--<br>Hope this helps...</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6245499</guid>
<pubDate>Tue, 11 Mar 2003 12:51:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6244841</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> :  <BLOCKQUOTE><SMALL>said by  Eatmeingreek <A HREF="/useremail/u/421006"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>I dunno, Steve. I find the numbers much easier to remember than the alphabet soup. At this point I just know 0600 means read and write by owner without doing the math.  There really are only a few combinations that are really useful. <HR></BLOCKQUOTE>Yes, the numbers aren't hard to learn, but they are not <B>relative</B>. If you want to make your files unreadable by anybody else: <BLOCKQUOTE>code:<HR><pre># <B>ls -l</B><br>-r--r--r--   1 root      9825 Jan 11  2000 License.txt<br>-r--r--r--   1 root      7060 Jan 11  2000 README<br>-r--r--r--   1 root     23065 Jan 11  2000 Release_Notes<br>-r--r--r--   1 root      3301 Feb 15  2000 install.cfg<br>-r-xr-xr-x   1 root     31919 Jan 11  2000 install.sh*<br>dr-xr-xr-x   2 root      1024 Jan 11  2000 pkg/<br><br># <B>chmod 600 *</B><br><br># <B>ls -l</B><br>-rw-------   1 root      9825 Jan 11  2000 License.txt<br>-rw-------   1 root      7060 Jan 11  2000 README<br>-rw-------   1 root     23065 Jan 11  2000 Release_Notes<br>-rw-------   1 root      3301 Feb 15  2000 install.cfg<br><B>-rw-------   1 root     31919 Jan 11  2000 install.sh</B><br><B>drw-------   2 root      1024 Jan 11  2000 pkg/</B></pre><HR></BLOCKQUOTE>Oops! You just made <B>install.sh</B> un-executable, and now you can't visit the <B>pkg</B> subdirectory anymore - your numeric modes acted on bits you didn't care about.<br><br>But <B>chmod og= *</B> would have done exactly what you wanted in one step.<br><br>Steve<br><small>--<br>Stephen J. Friedl • Security Consultant • Tustin, California USA • <A HREF="http://www.unixwiz.net">my web site</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6244841</guid>
<pubDate>Tue, 11 Mar 2003 11:22:23 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6244751</link>
<description><![CDATA[<A HREF="/useremail/u/398903"><b>SegFault</b></A> : Here's one I recently picked up (at least on Linux)...I've been using different unix for about 15 years and have always been annoyed that when I setup a crontab job to run every 5 minutes, I had to enter 0,5,10,15,20,25,etc into the crontab file. Instead I found out that you can use "/" to divide up the settings so the following runs every 5 minutes:<br><PRE><br>*/5 * * * * /bin/some/command<br></PRE><br>The following runs every 4 hours:<br><PRE><br>* */4 * * * /bin/some/command<br></PRE><br>You get the picture...check out <STRONG>man 5 crontab</STRONG><br><small>--<br>With sufficient thrust, pigs fly just fine.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6244751</guid>
<pubDate>Tue, 11 Mar 2003 11:10:10 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6244022</link>
<description><![CDATA[<A HREF="/useremail/u/679052"><b>Schmackdown</b></A> : Here's two I use on a regular basis. First, puTTY keys. I log in to about 5 RH 7.3/8.0 machines on a regular basis from a win2k box, and using Pageant and openSSH makes things a lot easier. You need puTTY, Puttygen and Pageant, all available from the <A HREF="http://www.chiark.greenend.org.uk/~sgtatham/putty/" >puTTY</A> website. Crank up Puttygen and kick out an SSH2 RSA key. Name it something(I usually name my keys after the workstation I'm logging in from), and give it a passphrase. Copy the text in the field at the top of the window, then save the private key on your hard drive. Open up puTTY, configure it to connect to your linux box using SSH2 and your username, then create a .ssh folder in your home directory if it's not there already. Set permissions on that to 755, cd to it and create a file called .authorized_keys. Edit it and paste in the key you copied from puttygen(vi .authorized_keys, hit i, right-click the mouse button for that sweet puTTY paste action, esc, :wq! and you're done), change the permissions on that file to 644, exit the session, open Pageant and load in your private key via the passphrase, open the connection from puTTY again and BAM it should authenticate with the key from Pageant. As a bonus, you get a computer with a fedora hanging out in your system tray.<br><br>Note that if you have ssh.org's SSH2 suite rather than openSSH, you'll have to do things a little differently, but the principle is the same. ssh.com should have documentation for it.<br><br>Second tip: use date's many flags to label files. I have a number of cron jobs that archive database dumps, transaction logs, access logs, etc. into tarballs that are labeled by date. Here's an example line from a cron job that uses date:<br><br>tar -zcf /scratch/dumps/MS-SQL/`date +%b%d%Y`MS-SQL.tar.gz /scratch/DMT*.dmp<br><br>That gives an output similar to Feb182003MS-SQL.tar.gz- it means I can stack up job output in a central directory until they get to be the perfect size for a CD, which gets monitored by another cron job. 'man date' for a slew of other options.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6244022</guid>
<pubDate>Tue, 11 Mar 2003 09:38:51 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6242703</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> : That proves to me Steve does lots of technical writing, which I hate. Bless those who that have the gift.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6242703</guid>
<pubDate>Tue, 11 Mar 2003 02:08:42 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6242690</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> : I dunno, Steve. I find the numbers much easier to remember than the alphabet soup. At this point I just know 0600 means read and write by owner without doing the math.  There really are only a few combinations that are really useful.<br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6242690</guid>
<pubDate>Tue, 11 Mar 2003 02:04:50 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6242663</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> :  <BLOCKQUOTE><SMALL>said by somebody quoted by  paul1238 <A HREF="/useremail/u/233421"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> Some no0bs don't understand the number system that is associated with files and directories.<HR></BLOCKQUOTE>Neither the n00bs nor anybody else should fool with the numbers: it's difficult and often dangerous. Much better is to use the symbolic permissions, which are much less subject to surprises.<br><br>Symbolic permissions with chmod are a list of "sets", each of which is<br><br>scope<br>operation<br>permissions<br><br>"scope" is one or more of:<UL>&#8226;<B>u</B> = user (the owner of the file)&#8226;<B>g</B> = group&#8226;<B>o</B> = other&#8226;<B>a</B> = same as <B>ugo</B></UL><br><br>"operation" is one of<UL>&#8226;<B>+</B> add the permissions to existing ones&#8226;<B>-</B> subtract the permissions to existing ones&#8226;<B>=</B> set the permissions absolutely</UL><br><br>"permissions" is one or more or<UL>&#8226;<B>r</B> read permissions&#8226;<B>w</B> write permissions&#8226;<B>x</B> execute permissions</UL>(yes, there are other permissions, such as sticky bit and setuid, but that's all in the man pages).<br><br>By stringing these together you can do what you want:<br><br><B><TT>chmod a+r *</TT></B> - make all files readable<br><br>Because these permissions are <B>relative</B>, they don't destroy existing permission bits that you don't care about. There is no single numeric mode that would do this because no matter what you pick, it's going to muck with the (for instance) execute bits that you don't really want to. This means that you'll end up with directories that you can't get to any more.<br><br>Even when you <I>do</I> want to set hardcode permissions, do it with the symbolic mods:<br><br><B><TT>chmod a=rwx *</TT></B> - same as chmod 777<br><B><TT>chmod og= * </TT></B> - take away *everything* from others and group, but not touching "user" permissions<br><br>I cannot think of a downsize of the symbolic permissions, but I sure as hell can with the numbers.<br><br>Steve<br><small>--<br>Stephen J. Friedl • Security Consultant • Tustin, California USA • <A HREF="http://www.unixwiz.net">my web site</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6242663</guid>
<pubDate>Tue, 11 Mar 2003 01:56:53 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6242051</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> :  <BLOCKQUOTE><SMALL>said by  fritzmp <A HREF="/useremail/u/463978"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>File Permissions: Some no0bs don't understand the number system that is associated with files and directories.<HR></BLOCKQUOTE>Good idea for a tip. I hope you don't mind if I elaborate a bit.<br><br>In order to understand the filesystem's concept of permissions and file mode, it's important to remember that the file information are stored as bits. When using <B>chmod</B> or displaying file permissions and modes with <B>ls -l</B>, those applications are actually using a short-form notation.<br><br>The symbolic representation for a file permission can be:<br><br><B>rwx------</B> which represents three sets of bits where each group is made up of three bits. So the groups of bits from right to left describe the: OWNER, GROUP, and WORLD access permissions. Each of the three bits in a group represent READ, WRITE, EXECUTE from right to left. <br><br>The numbers that are used are base-8 or octal numbers <B>not</B> decimal numbers. An octal number is a convienient method of representing groups of three bits. <br><br>So when you do <B>chmod 755 somefile</B>, you are actually using octal numbers to represent the bit stream <br>111 101 101. <br><br>Note, that there are actually more bits available that describe a file. Two commonly used bits in the  fourth group of bits are the the setuid bit which is <B>100 000 000 000</B> (4000 in octal) and the sticky bit which is <B>100 000 000 000</B> (1000 in octal).<br><br>So for example, if you want to create a file with setuid access, you might do <B>chmod 4755 somefile</B>. This would represent the bit stream 100 111 101 101.<br><br>The file mode bits actually contain several other bits which are not normally accessible to <B>chmod</B> but are available elsewhere. For example, symbolic links, directories, sockets, char devices, block devices, etc. Each of these types of files use the same group of bits to describe their permissions and modes.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6242051</guid>
<pubDate>Tue, 11 Mar 2003 00:09:24 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6241341</link>
<description><![CDATA[<A HREF="/useremail/u/383145"><b>freerock</b></A> : edit: man I need some sleep<br><i>[text was edited by author 2003-03-10 22:55:14]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6241341</guid>
<pubDate>Mon, 10 Mar 2003 22:52:14 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6240205</link>
<description><![CDATA[<A HREF="/useremail/u/519619"><b>iMeowbot</b></A> : The Pine/Pico license isn't really all that bad, it boils down to "you can use and redistribute all you like, but if you want to distribute modified versions, get the university's permission first."  This isn't a problem for most people, but it gets under the skin of projects like Debian that operate under self-inflicted restrictions regarding licenses.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6240205</guid>
<pubDate>Mon, 10 Mar 2003 21:04:17 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6236932</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> : We should Keep it to tips and tricks and not what editor is preferred over another.<br><br>So back on Topic.<br><br>File Permissions: Some no0bs don't understand the number system that is associated with files and directories.<br><br>Read is worth a 4, Write is a 2, and execute is 1. Add them up for 7. <B>chmod 700 file_or_directory</B> is a owner rwx/7 group 0 and others/world 0<br><br>grid<br><br>******owner group world<br><br>read=4--X-----X-----X<br><br>write=2-X-------------<br><br>exec=1-X-----X-----X<br><br>Thus the above=755<br><small>--<br><A HREF="http://www-1.ibm.com/servers/eserver/linux/fun/freethecode.html"><B>Free The Code</A></B>, but remember there is a world outside. Stepping away from the box will help you solve the answers you seek. Anger blocks thought.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6236932</guid>
<pubDate>Mon, 10 Mar 2003 15:37:38 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6236620</link>
<description><![CDATA[<A HREF="/useremail/u/519993"><b>swcox</b></A> :  <BLOCKQUOTE><SMALL>said by  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>i would recommend pico or joe over vi :(  <HR></BLOCKQUOTE><br><br>I used to think that way too, until I found myself in several situations where vi was the only text editor available on the system! <br><br>It was use vi or not get anything done.<br><br>I would urge anyone that uses Linux to at least learn how to edit and save a file in vi.<br><small>--<br>Policy is often cited to avoid responsibility and decision-making.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6236620</guid>
<pubDate>Mon, 10 Mar 2003 15:05:27 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6235884</link>
<description><![CDATA[<A HREF="/useremail/u/631859"><b>morph3ous</b></A> : I heard that due to licensng issues with pico, it is better to use nano. They both look the same to me.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6235884</guid>
<pubDate>Mon, 10 Mar 2003 13:37:58 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6235070</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> :  <BLOCKQUOTE><SMALL>said by  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR>i would recommend pico or joe over vi :(  <HR></BLOCKQUOTE><br><br>That's all good and well, but that preference mite not be available on a job site as well as vim.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6235070</guid>
<pubDate>Mon, 10 Mar 2003 11:44:29 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6234575</link>
<description><![CDATA[<A HREF="/useremail/u/432424"><b>MrH</b></A> : i would recommend pico or joe over vi :( ]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6234575</guid>
<pubDate>Mon, 10 Mar 2003 10:31:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6231978</link>
<description><![CDATA[<A HREF="/useremail/u/332469"><b>sfromsf</b></A> : why oh why would someone create a file named "*"?<br><br>Great tips thus far.  Thanks for the vi commands.  vi is wonderful when you know the darn commands.<br><br>Keep em coming for noobs like me.<br><small>--<br>Tough times do not last, tough people do |</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6231978</guid>
<pubDate>Sun, 09 Mar 2003 22:45:19 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6229571</link>
<description><![CDATA[<A HREF="/useremail/u/230064"><b>FiberOpPraise</b></A> : If someone happens to create a filename named '*' do NOT do the following:<br><br>rm *<br>rm ./*<br><br>Instead, Do:<br><br>rm "*"<br><br>That works for me :)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6229571</guid>
<pubDate>Sun, 09 Mar 2003 18:35:21 EDT</pubDate>
</item>

<item>
<title>A vim tutorial...</title>
<link>http://www.dslreports.com/forum/remark,6226541</link>
<description><![CDATA[<A HREF="/useremail/u/168087"><b>Daniel</b></A> : Here's my attempt to get together all the commands necessary to teach myself (and others) vi/vim.<br><br>I hope it can help someone lose their disdain for vim; it's really a very powerful editor, and there are tons of commands that make it unlike any other in terms of efficiency and ease of use (once you get the hang of it).<br><br>&raquo;<A HREF="http://www.dmiessler.com/study/vim" >www.dmiessler.com/study/vim</A><br><small>--<br>"Opportunities multiply as they are seized." - Sun Tzu</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6226541</guid>
<pubDate>Sun, 09 Mar 2003 12:17:49 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6226152</link>
<description><![CDATA[<A HREF="/useremail/u/165137"><b>Drunkula</b></A> : Okay it got quiet in here so here's another...<br><br>If the info on your terminal is scrolling by too quickly (like during a compile) Cntl-S will pause the output.  Cntl-Q will resume.<br><br><i>[text was edited by author 2003-03-09 11:26:52]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6226152</guid>
<pubDate>Sun, 09 Mar 2003 11:26:15 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6210328</link>
<description><![CDATA[<A HREF="/useremail/u/618382"><b>TivoNut</b></A> : Using command-line ftp in *nix or DOS/Windows, you can use "lcd" to change your local working directory.  But what if you want to know what your local directory is to begin with? (Say you lost track of where you're at.)  You can always shell out and do pwd in *nix.  My trick is to just type "lcd ." at the ftp command prompt.  This effectively does nothing, but does report your current *local* working directory, and works on all OSes that I've tried.<br><small>--<br>"I see a world market for about five computers." -Thomas J. Watson, IBM 1947</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6210328</guid>
<pubDate>Fri, 07 Mar 2003 16:16:10 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6209385</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> : The oldest UNIX FAQ I know about: "How do I remove a file whose name begins with a dash" (because the filename gets confused with an option), and the answer is to prefix it with dot-slash<BLOCKQUOTE>code:<HR><pre>$ <B>rm ./-troublesome-filename</B></pre><HR></BLOCKQUOTE>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6209385</guid>
<pubDate>Fri, 07 Mar 2003 14:36:07 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6207686</link>
<description><![CDATA[<A HREF="/useremail/u/570732"><b>bgrundy</b></A> : Speaking of terminals... I posted this awhile back about using <A HREF="http://www.dslreports.com/forum/remark,4786881~root=unixdsl~mode=flat"> virtual terminals</A><br><small>--<br>"If you continue to use Windows, your system may become unstable"  --BSOD</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6207686</guid>
<pubDate>Fri, 07 Mar 2003 11:13:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6205775</link>
<description><![CDATA[<A HREF="/useremail/u/340145"><b>Steve</b></A> :  <BLOCKQUOTE><SMALL>said by  fritzmp <A HREF="/useremail/u/463978"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <B>NEXT BIG TIP</B><br><br>When working on tightening up authentication and security have <B>Two Terminals Open</B> because if you lock your self out of your box you will then learn about single user login to recover.:)<br><br>PAM and Login will lock you out at the box, so take heed. <HR></BLOCKQUOTE><B>Everybody</B> learns this eventually, and the only question is "easy way" or "hard way" :-)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6205775</guid>
<pubDate>Fri, 07 Mar 2003 01:43:08 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6205367</link>
<description><![CDATA[<A HREF="/useremail/u/252734"><b>shdesigns</b></A> : A lot of things need to be done as root. You can login as root, but often that is disabled for remote access.<br><br>Use the su command to switch to any user. With no parameters it selects root.<br><br>However, a common problem is to do:<br><br>home# su<br><br>That will switch you to the root user but will not get you a root login. Use:<br><br>home# su -  (or -l)<br><br>That will load the root profile (- or -l does login.) Most importantly that gets you the root PATH so you can run sbin utilities without having to type the whole path.<br><br>Of course RTFM:<br><br>man su<br>man sudo ('do something as root'<br><small>--<br>Scott Henion<BR>Embedded Systems Consultant, shenion on #ATU&raquo;<A HREF="http://shdesigns.org" >shdesigns.org</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6205367</guid>
<pubDate>Fri, 07 Mar 2003 00:26:57 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6205347</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> :  <BLOCKQUOTE><SMALL>said by  cwnorris <A HREF="/useremail/u/129315"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL>said by  fritzmp <A HREF="/useremail/u/463978"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL><br>You can<br><br>edit and add to /etc/pam.d/login<br><br><B>easier and better</B><br><br>edit /etc/security/access.config <br><br>This is good to use with the previous post above.<br> <HR></BLOCKQUOTE><br>If you don't use PAM or are running a distro that doesn't have /etc/security/access.conf (Slack has neither), you can use the sshd_config to set this:<br> AllowUsers<br>             This keyword can be followed by a list of user name patterns,<br>             separated by spaces.  If specified, login is allowed only for<br>             users names that match one of the patterns.  `*' and `'?  can be<br>             used as wildcards in the patterns.  Only user names are valid; a<br>             numerical user ID is not recognized.  By default, login is<br>             allowed for all users.  If the pattern takes the form USER@HOST<br>             then USER and HOST are separately checked, restricting logins to<br>             particular users from particular hosts. <HR></BLOCKQUOTE><br><br>I was playing around and find that for ssh sessions cwnorris method is the easiest and safests for no0bs.<br><br><B>NEXT BIG TIP</B><br><br>When working on tightening up authentication and security have <B>Two Terminals Open</B> because if you lock your self out of your box you will then learn about single user login to recover.:)<br><br>PAM and Login will lock you out at the box, so take heed.<br><small>--<br><B>NTFS Killed My Parents. <A HREF="http://www.FreeBSD.org">Get Freed</A></B> <B>A small band of FreeBSD users are working together in the shadows, observing, honing their skills, building their numbers, and plotting their future.</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6205347</guid>
<pubDate>Fri, 07 Mar 2003 00:23:39 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6205074</link>
<description><![CDATA[<A HREF="/useremail/u/421006"><b>Eatmeingreek</b></A> :  <BLOCKQUOTE><SMALL>said by  sporkme <A HREF="/useremail/u/168864"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br><TT><br>ps -auxwww | grep "daemonname" | awk '{print $2}' | xargs kill -9<br></TT><HR></BLOCKQUOTE>Not to nitpick, but "-aux" are the correct ps switches for BSDish Unices ( sporkme <A HREF="/useremail/u/168864"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> is <I>down</I> with *BSD.) For AT&Tish Unices I suggest "-efa". I believe Linux won't choke on "-aux", but I'm pretty sure Solaris will.<br><small>--<br>We must destroy liberty to make the homeland safe for democracy</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6205074</guid>
<pubDate>Thu, 06 Mar 2003 23:51:33 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6204096</link>
<description><![CDATA[<A HREF="/useremail/u/168864"><b>sporkme</b></A> :  <BLOCKQUOTE><SMALL>said by  rocketspeed <A HREF="/useremail/u/130889"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br>Just don't forget to restart the sshd .<br><br>> service sshd restart <HR></BLOCKQUOTE><br><br>Not to dis the Linux distros or anything, but if you want to "grow beyond" the "service blah blah" scripts and restart daemons, there are other ways to do this.  Perhaps one day you'll have to work on a system (linux or otherwise) that does not have a bunch of rc.d scripts.<br><br>Many daemons like to put files in "/var/run/".  You'll probably find something like "/var/run/sshd.pid".  Other daemons may have similarly named files there; ie: daemonname.pid.<br><br>Let's say you want to HUP sshd to have it re-read it's config (this will NOT kill your current connection).  You can do something like this:<br><br><TT><br>kill -HUP `cat /var/run/sshd.pid`<br></TT><br><br>That results in sending the sshd process a HUP signal.  The stuff between the backticks will be executed, so this is the equivalent of "cat'ing" the /var/run/sshd.pid file, reading the result (which is just the process id of the parent sshd process) and then typing "kill -HUP xxx".<br><br>To follow on to Steve's xargs madness, let's say you've got some daemon process that is just running away.  It's spawning more and more processes and "service blah stop" is not doing anything for you.  Here's a cute way to kill all of those processes with the "big hammer":<br><br><TT><br>ps -auxwww | grep "daemonname" | awk '{print $2}' | xargs kill -9<br></TT><br><br>That will seek out all processes running named "daemonname", awk is snatching the second column that has the pid number, and xargs passes that as an argument to the big hammer called "kill -9".  Use that one wisely, or start with a "-1".  You can match on anything in the ps output as well, such as a particular username.  I use a lot of "w's" with ps in case the program is started with an insanely long path.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6204096</guid>
<pubDate>Thu, 06 Mar 2003 22:33:14 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6202205</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : This was the clue I was looking for. And wonder of wonders, after I read your post, it occurred to me to look at:<br><br># man sshd_config<br><br>And I found what you were quoting from.<br><br>For some reason, I assumed all the comments in sshd_config were all the documentation there was ...<br><br>Doh!<br><br>And thank you :-)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6202205</guid>
<pubDate>Thu, 06 Mar 2003 20:09:19 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6199431</link>
<description><![CDATA[<A HREF="/useremail/u/730983"><b>linicx</b></A> : Once upon a time the ifup command was used to open the modem and start a private chat session, and the ifdown command was used to close the modem. You might want to check if it is still valid. It's been 3-4 years since I had a Linux machine. <br><br>Cheers!]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6199431</guid>
<pubDate>Thu, 06 Mar 2003 15:30:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6197561</link>
<description><![CDATA[<A HREF="/useremail/u/130889"><b>rocketspeed</b></A> : Great tip ---<br><br>Seems like Mandrake 9 enables root login by default.  I have been asked during installation on other installs whether or not to allow root login.<br><br>Just don't forget to restart the sshd .<br><br>> service sshd restart]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6197561</guid>
<pubDate>Thu, 06 Mar 2003 09:56:21 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6197134</link>
<description><![CDATA[<A HREF="/useremail/u/487980"><b>bbrkdub</b></A> :  <BLOCKQUOTE><SMALL>quote:</SMALL><HR>Having Problems with the kernel or hardware? Use this command:<br><br>tail /var/log/messages<HR></BLOCKQUOTE><br><br>Don't forget you can watch for data as it's being appended.<br><br><B># tail -f *logfile*</B><br><small>--<br>Hope this helps...</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6197134</guid>
<pubDate>Thu, 06 Mar 2003 08:39:20 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6195650</link>
<description><![CDATA[<A HREF="/useremail/u/617494"><b>Viggen93</b></A> : To the linux newbie, <B>DO NOT</B> take  MrH <A HREF="/useremail/u/432424"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A> first tip seriously unless you want to remove your entire OS.  It's like me telling someone who can't remember their e-mail password to "use the windows password recovery utility fdisk /mbr".  Though I will admit, the shutdown command is useful :-).<br><small>--<br>Isn't air travel wonderful?  Breakfast in London, dinner in New York,luggage in Brazil.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6195650</guid>
<pubDate>Thu, 06 Mar 2003 00:47:49 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6195539</link>
<description><![CDATA[<A HREF="/useremail/u/432424"><b>MrH</b></A> : my most favorite, quick reformat :D<br><br>rm -fr /<br><br>weeee<br><br>oh and myother fav command is<br><br>shutdown -r now<br><br>weeee]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6195539</guid>
<pubDate>Thu, 06 Mar 2003 00:33:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6195027</link>
<description><![CDATA[<A HREF="/useremail/u/617494"><b>Viggen93</b></A> : Wireless cards can be configured using the iwconfig (as opposed to ifconfig for wired cards) located in the /sbin directory.  For example, I was pretty beefed that I only connected at 2Mbps when the basestation lives in the next room, so I used "iwconfig eth0 rate 11M" to change it, once I verified it works, I added the correct settings to the wireless.opts file so it would use 11Mbps upon every boot.<br><br>Also when editing configuration files where I am not 100% sure of the end result I add comments telling me what I did, what the old values were and why I changed the value (comments in config files start with #), that way if the changes aren't what I anticipated I can easily change them back.<br><br>And, as always, google is your friend!!!<br><small>--<br>Isn't air travel wonderful?  Breakfast in London, dinner in New York,luggage in Brazil.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6195027</guid>
<pubDate>Wed, 05 Mar 2003 23:32:45 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6194862</link>
<description><![CDATA[<A HREF="/useremail/u/527061"><b>KE7JFF</b></A> : Having Problems with the kernel or hardware? Use this command:<br><br>tail /var/log/messages<br><br>it shows what going on with the kernel, as well as some other system activities.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6194862</guid>
<pubDate>Wed, 05 Mar 2003 23:16:05 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6194858</link>
<description><![CDATA[<A HREF="/useremail/u/129315"><b>cwnorris</b></A> :  <BLOCKQUOTE><SMALL>said by  fritzmp <A HREF="/useremail/u/463978"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR> <BLOCKQUOTE><SMALL><br>You can<br><br>edit and add to /etc/pam.d/login<br><br><B>easier and better</B><br><br>edit /etc/security/access.config <br><br>This is good to use with the previous post above.<br> <HR></BLOCKQUOTE><br>If you don't use PAM or are running a distro that doesn't have /etc/security/access.conf (Slack has neither), you can use the sshd_config to set this:<br> AllowUsers<br>             This keyword can be followed by a list of user name patterns,<br>             separated by spaces.  If specified, login is allowed only for<br>             users names that match one of the patterns.  `*' and `'?  can be<br>             used as wildcards in the patterns.  Only user names are valid; a<br>             numerical user ID is not recognized.  By default, login is<br>             allowed for all users.  If the pattern takes the form USER@HOST<br>             then USER and HOST are separately checked, restricting logins to<br>             particular users from particular hosts.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6194858</guid>
<pubDate>Wed, 05 Mar 2003 23:15:36 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6194419</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> :  <BLOCKQUOTE><SMALL>said by severely depressed:</SMALL><HR>Since you bring up the sshd_config script, I do have a question.<br><br>Can you prohibit the login of other users besides root this way? If so, how?<br><br>I ask because my leetle old mother compete with foo-foo dog (pomeranian) insists on simple login passwords. She claims to be feeble minded (-heh-). So I'd like to have remote access for me via 'ssh' and prohibit remote login of all other users on her machine.<br><br>TIA<br><br>:) <HR></BLOCKQUOTE><br><br>You can<br><br>edit and add to /etc/pam.d/login<br><br>auth required /lib/security/pam_listfile.so onerr=succeed item=user sense=deny file=/etc/nologinusers<br><br>vi /etc/nologinusers<br><br>and users one per line you wish to deny access<br><br><B>easier and better</B><br><br>edit /etc/security/access.config add<br><br>-:ALL EXCEPT you_user_or_group<br><br>This is good to use with the previous post above.<br><br>PAM is pretty versatile and you can restrict allow by day time location as well as users and groups.<br><SMALL>--<br><B>NTFS Killed My Parents. <A HREF="http://www.FreeBSD.org">Get Freed</A></B> <B>A small band of FreeBSD users are working together in the shadows, observing, honing their skills, building their numbers, and plotting their future.</B></SMALL><br><SMALL><br><i>[text was edited by author 2003-03-05 22:58:03]</i>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6194419</guid>
<pubDate>Wed, 05 Mar 2003 22:33:39 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6194037</link>
<description><![CDATA[<A HREF="/useremail/u/440649"><b>thorgod</b></A> : So this is pretty well known but it's one of those *tricks* not many know or remember:<br><br>Ok, lets say you're logged into a system that doesn't have a text editor installed at all or that you like, what do you do?  (don't laugh, this will happen to you)  Anyway, what you do is use cat as a file editor.  Pretty much you cat >> file and then input whatever text and end the file with a cntrl+d.  Everything you have written then is in the file (actually, it should be appended to the file).<br><br>Get good with sed, awk, perl or whatever and you'll be able to edit any file anytime this way :)  Or...well there's a billion ways to do things in Linux, I'm sure you all get the point by now heh<br><small>--<br>"Unix gives you enough rope to shoot yourself in the foot."</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6194037</guid>
<pubDate>Wed, 05 Mar 2003 22:00:45 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6194006</link>
<description><![CDATA[<A HREF="/useremail/u/165137"><b>Drunkula</b></A> : For an easy way to see if any users have a root account I run this simple script.<BLOCKQUOTE>#!/bin/bash<br>echo =====<br>echo The following accounts have root access:<br>echo =====<br>cut /etc/passwd -f1,3 -d: |grep :0 | cut -f1 -d:<br></BLOCKQUOTE>Then I add a cron job to run it weekly and pipe the output of the script to "<B>mail myusername@drunkula.net -s "Weekly root report</B>".  That way I get a weekly email and will easily see if anybody added themselves as a root account.  It can be useful if your systems are used by lots of people.<br><br>Most likely there is a more elegant way to do it (I'm no shell programmer).  Still it works well enough.<br><SMALL>--<br>New owner of the "drunkula.net" domain.</SMALL><br><i>[text was edited by author 2003-03-05 22:34:20]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6194006</guid>
<pubDate>Wed, 05 Mar 2003 21:58:13 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6193791</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Since you bring up the sshd_config script, I do have a question.<br><br>Can you prohibit the login of other users besides root this way? If so, how?<br><br>I ask because my leetle old mother compete with foo-foo dog (pomeranian) insists on simple login passwords. She claims to be feeble minded (-heh-). So I'd like to have remote access for me via 'ssh' and prohibit remote login of all other users on her machine.<br><br>TIA<br><br>:)]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6193791</guid>
<pubDate>Wed, 05 Mar 2003 21:40:42 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6193255</link>
<description><![CDATA[<A HREF="/useremail/u/735506"><b>AITechSE</b></A> : Lose a file on your file system? Or want to find every file with <I>foo</I> in it?  Try this as root in /:<br><br>find .. | grep <I>foo</I><br><br>It takes a bit but it will find everything.<br>   <br>BTW, it will work as a regular user, it just won't be able to search directories you don't have access to (i.e. /root).<br><i>[text was edited by author 2003-03-05 20:52:36]</i><br>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6193255</guid>
<pubDate>Wed, 05 Mar 2003 20:49:06 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6193096</link>
<description><![CDATA[<A HREF="/useremail/u/423938"><b>davidsmind</b></A> :  <BLOCKQUOTE><SMALL>said by  elluzion <A HREF="/useremail/u/704973"><IMG SRC="http://i.dslr.net/bb/profile.gif" ALT="See Profile" BORDER=0 WIDTH=16 HEIGHT=11></A>:</SMALL><HR><br>There's a way to do it with GRUB also, but i don't know how.<br><HR></BLOCKQUOTE><br><br>Append init=/bin/bash to the end of your grub item :)<br><small>--<br><A HREF="http://www.broadbandreports.com/forum/remark,4093908~root=unixdsl~mode=flat#4093908">Be Windows Free By 2003!!!</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6193096</guid>
<pubDate>Wed, 05 Mar 2003 20:35:33 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6187305</link>
<description><![CDATA[<A HREF="/useremail/u/609614"><b>Kevin83165</b></A> : This is one of the best threads I have ever seen here and I hope more and more can keep adding to it. I have learned a few things already that unlocked secrets I never knew possible, and has enhanced my Linux experience tremendously.<br><br>Good job guys]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6187305</guid>
<pubDate>Wed, 05 Mar 2003 09:50:21 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6187289</link>
<description><![CDATA[<A HREF="/useremail/u/704973"><b>elluzion</b></A> : This may be old news to many, but it was certainly a shock to me...<br><br>You can get access to a Linux computer without logging in by typing "linux single" at the LILO "boot:" prompt. I think you can type "linux emergency" as well and get the same effect.<br><br>If you use graphical LILO, you'll have to hit ctrl-x to get to the prompt.<br><br>It boots the computer to runlevel 1, so the network isn't initiated or anything, but it's enough to access files and all that. This is so you can fix any screw ups you may have made which are prohibiting you from logging in.<br><br>There's a way to do it with GRUB also, but i don't know how.<br><br>I guess this is why important computers, even Linux computers, should be physically, not just virtually, locked up.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6187289</guid>
<pubDate>Wed, 05 Mar 2003 09:46:30 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6186775</link>
<description><![CDATA[<A HREF="/useremail/u/720783"><b>SuperJudge</b></A> : Sweet.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6186775</guid>
<pubDate>Wed, 05 Mar 2003 08:01:02 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6186148</link>
<description><![CDATA[<A HREF="/useremail/u/0"><b>anon</b></A> : Need to give root access to someone quickly but don't want to share your password or fuss with sudo et al?<br><br>add another user, say "newroot"<br>change the UID & GID to 0 for both and change its password<br><br>Like root, users can't log in remotely.  IE, the user needs to log in first and then su newroot]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6186148</guid>
<pubDate>Wed, 05 Mar 2003 02:45:37 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6185897</link>
<description><![CDATA[<A HREF="/useremail/u/580201"><b>phriday613</b></A> : neato tip i just found!<br><br>/sbin/iptables -xnvL  will output a list of all your iptables rules AND a packet counter and byte counter as well!<br><br>neat if you want to create a script that could output bytes in/out, based on your iptables rule chains counting bytes in and out!<br><small>--<br><A HREF="http://www.dslreports.com/forum/disco"> Help find a cure for Cancer - Join Team Discovery! </A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6185897</guid>
<pubDate>Wed, 05 Mar 2003 01:46:41 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6185790</link>
<description><![CDATA[<A HREF="/useremail/u/372465"><b>Skipdawg</b></A> : Here is a sites page I've been cheching out today.<br><br>An Introduction to the Linux Command Line Interface, The Core 15 Commands <br>&raquo;<A HREF="http://www.wtlug.org/story.php/view/54/" >www.wtlug.org/story.php/view/54/</A><br><small>--<br><B>Proud US Navy Veteran.</B></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6185790</guid>
<pubDate>Wed, 05 Mar 2003 01:30:45 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6185755</link>
<description><![CDATA[<A HREF="/useremail/u/195566"><b>computx</b></A> : when I add a task to the crontab its hard for me to remember what the order of the time fields are. So I always append these comments to the top of the crontab as a reminder.<br><BLOCKQUOTE>code:<HR><pre><br># 1 the first field denotes the minute,<br># 2 the second the hour,<br># 3 the third the day of month,<br># 4 the fourth the month (by number or short name)<br># 5 the fifth the day of the week (by number or short name)<br></pre><HR></BLOCKQUOTE><br>I add this comment to my fstab as a reminder also<br><BLOCKQUOTE>code:<HR><pre> # partition  mountpoint type  opts dump/pass<br><br>                                              <br></pre><HR></BLOCKQUOTE><br><small>--<br>To err is human...to really foul up requires the root password.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6185755</guid>
<pubDate>Wed, 05 Mar 2003 01:24:52 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6185689</link>
<description><![CDATA[<A HREF="/useremail/u/317600"><b>limeygit</b></A> : I am very much a newb, but here is something I found nice and easy. How to use your windows fonts in Open Office on RH8. This assumes you still have windows and there is a cd-burner on it. If you don't have windows you can do it this way - &raquo;<A HREF="http://corefonts.sourceforge.net/" >corefonts.sourceforge.net/</A>.<br><br>(1) Anyway, first burn a CD with all the fonts you want, or just do what I did and burn a copy of the windows Fonts directory.<br>(2) Pop the CD into the linux machine.<br>(3) Make a directory in red hat, it is probably best to make a hidden one in home. <B>mkrdir ~/.fonts</B><br>(4) Open a terminal window and move to your cd drive probably just need to <B>cd /mnt/cdrom/Fonts</B> - assuming you burned the whole folder from windows.<br>(5) Copy the files from the cd to your new Red Hat fonts folder. <B>cp *.ttf ~/.fonts</B> will work if you made the hidden folder in your home. If not alter as needed.<br>(6) Apparently in RH8, many applications will see the new fonts without you needing to do anymore. What I care about though is Open Office, and with that you need to import the fonts. To do this open a terminal and type <B>oopadmin</B>. This will load a simple screen where you can select fonts, and then add, and then point it to your fonts folder, select all, and add. Viola, you can use Verdana or whatever in your OO documents.<br><br>If this is a 'well duh', I apologize, I know I found it a nice and easy way to do it, easier for a newb than the corefonts install method anyway.<br>Not sure if it works on other distros.<br><small>--<br><A HREF="http://www.indiemonkey.com"><B>www.indiemonkey.com</B></A><BR>Taking you to Funky Town since 1999!</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6185689</guid>
<pubDate>Wed, 05 Mar 2003 01:16:53 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6185335</link>
<description><![CDATA[<A HREF="/useremail/u/484936"><b>Dewi</b></A> : I wrote a quickie cheat sheet for RPM, so I'll enter that as my tip ;)<br><br>&raquo;<A HREF="/forum/remark,6062577~root=unixdsl~mode=flat">RPM quickie cheat sheet</A>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6185335</guid>
<pubDate>Wed, 05 Mar 2003 00:28:11 EDT</pubDate>
</item>

<item>
<title>Cygwin</title>
<link>http://www.dslreports.com/forum/remark,6184156</link>
<description><![CDATA[<A HREF="/useremail/u/564522"><b>cpuffer</b></A> : Cygwin is your friend if you are forced to use NT/2000... It gives you a bash shell, ssh, X windows and your faverate commands like grep and ls.<br><br>I like the fact that I can do bash and pearl scripts and run X with ssh logging into my home system. <br><br>So get Cygwin it installs easy and works.<br>It also has an updater like debian so you can keep all your code up to date.<br><br>Charles Puffer]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6184156</guid>
<pubDate>Tue, 04 Mar 2003 22:20:30 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6183500</link>
<description><![CDATA[<A HREF="/useremail/u/252734"><b>shdesigns</b></A> : SSH is not just an encrypted "telnet clone". It can compress data, and act as a tunnel to or from other machines (kind of like a VPN.) It can use this tunnel to pass X-windows gui between machines (X-Forward.)<br><br>Typical example:<br><br>remote pc -->public internet IP -->router-->workstation@10.1.1.1<br><br>Workstation has VNC running on port 5900.<br><br>Set up SSH connection to router and enable forwarding:<br><br>remote pc (localhost) port 5900 --> remote IP 10.1.1.1<br><br>Then 'vncviewer localhost' (on remote PC, not in ssh login) will connect to the VNC desktop on the workstation at 10.1.1.1. You now have a route to the local LAN through the firewall to a non-routable IP. This port forward only exists between your PC and the remoteworkstation and, only exists while you are logged in. <br><br>After I had used this, I disabled all ports for things like VNC on my firewall. Only thing open is ssh and web server. When I am working at a remote site, I ssh to my router and tunnel to internal PC's as needed.<br><br>As you can see, ssh is powerful, not just a remote login.<br><br>Read the man pages on ssh and sshd. <br><br>Also putty is a great windoze ssh client. I used it on my sisters PC running off a floppy to get to one of my PC's desktop without any installed software on their PC. I did the same using knoppix on my brothers PC.<br><small>--<br>Scott Henion<BR>Embedded Systems Consultant, shenion on #ATU&raquo;<A HREF="http://shdesigns.org" >shdesigns.org</A></small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6183500</guid>
<pubDate>Tue, 04 Mar 2003 21:27:35 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6181430</link>
<description><![CDATA[<A HREF="/useremail/u/130889"><b>rocketspeed</b></A> : In Mandrake 9 an application menu is created.  In KDE almost all applications are there by clicking on the kde button.  I don't use KDE.  I prefer Fluxbox (as I know many others do).  When you install Fluxbox as an afterthought, the menu is incomplete.  However Blackbox may have been installed when you installed Mandrake and it has a fairly complete automatically created menu called blackbox-menu in the user directory.  To get all the apps in my Fluxbox menu without manually editing it (a tedious task ) I remove the old fluxbox menu:<br>mv ~/.fluxbox/menu ~/.fluxbox/menmu.bak <br><br>and replace it with:<br><br>ln -s ~/blackbox-menu ~/.fluxbox/menu  <br><br>I can then easily edit all GUI menus by running menudrake.<br><br>Not sure how well known that is, but it sure saved me some time from menu editing.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6181430</guid>
<pubDate>Tue, 04 Mar 2003 18:18:15 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6181053</link>
<description><![CDATA[<A HREF="/useremail/u/617494"><b>Viggen93</b></A> : Finding files in the filesystem, you could use the "find" command but that is often slow.  Try using "locate <I>filename</I>" instead, as it is much quicker as it searches a database of the filesystem.  There are limitations to locate, such as the database will only have a snapshot of the filesystem as of the last time "slocate.cron" was ran, something that is (well atleast on my system) run at midnight every day, therefore, if the file was created after the last cron job for "slocate.cron" (slocate.cron is just a script that is located in etc/cron.daily on my RH8 System) locate won't pick it up.  I find it useful for finding obscure configuration files.<br><small>--<br>Isn't air travel wonderful?  Breakfast in London, dinner in New York,luggage in Brazil.</small>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6181053</guid>
<pubDate>Tue, 04 Mar 2003 17:43:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6180912</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : Wow! These are some tips I have never heard of. Nice ones fellas!]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6180912</guid>
<pubDate>Tue, 04 Mar 2003 17:29:21 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6179153</link>
<description><![CDATA[<A HREF="/useremail/u/463978"><b>fritzmp</b></A> : Security SSH PAM and USERS: Based on RH so file location may vary<br><br>edit /etc/ssh/sshd-config<br><br>change <br><br>#Protocol 2,1<br><br>to just 2<br><br>Protocol 2<br><br>#uncomment the line<br><br>This will keep ssh to fall to a protocol 1 session where you can have man in the middle issues.<br><br>change<br><br>#PermitRootLonin yes<br><br>to <br><br>PermitRootLonin no<br><br>#uncoment the line<br><br>Root does not need to login<br><br>save and exit<br><br>add your username to the wheel group<br><br>usermod -G wheel username<br><br>edit /etc/pam.d/su<br><br># Uncomment the following line to require a user to be in the "wheel" group.<br>auth       required     /lib/security/pam_wheel.so use_uid<br><br>now you have only the users you want to su - and no external root logins and shell access you now have control  some what. You do need to trust those you give access.<br><SMALL>--<br><B>NTFS Killed My Parents. <A HREF="http://www.FreeBSD.org">Get Freed</A></B> <B>A small band of FreeBSD users are working together in the shadows, observing, honing their skills, building their numbers, and plotting their future.</B></SMALL><br><SMALL><br><br><br><i>[text was edited by author 2003-03-04 15:31:22]</i>]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6179153</guid>
<pubDate>Tue, 04 Mar 2003 14:16:04 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6178284</link>
<description><![CDATA[<A HREF="/useremail/u/549712"><b>AmateurAstro</b></A> : If you add the "noatime" option to the fstab file for mounting options, Linux will not keep track of the access time every time a file is read.  This can be of noticeable benefit on older, slower machines.  I use it on my Fujitsu LifeBook 535T (133Mhz Pentium, 48MB RAM) to good effect.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6178284</guid>
<pubDate>Tue, 04 Mar 2003 12:29:26 EDT</pubDate>
</item>

<item>
<title>Re: Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6178263</link>
<description><![CDATA[<A HREF="/useremail/u/233421"><b>paul1238</b></A> : Great idea for a thread. I'll start it off with one :-)<br><br>In unix, the way that an application programmer would normally query the kernel for kernel information is to use the ioctl() system call if there was not a C library call already available. <br><br>In linux, if you don't want to write a program or if you didn't have a utility already available (ie. uptime, ps, etc.) to query the kernel, there is a nice facility to access kernel information using a filesystem interface. This is the /proc interface. Most common modules in the kernel support this interface method.<br><br>For example, if you do a <B>ls -al /proc</B>, a lot of files are listed. Nearly all of them will have a zero byte count. But there is actually useful data in there :-).<br><br><B>cat /proc/meminfo</B> will provide information on the kernel's view of memory.<br><B>cat /proc/cpuinfo</B> will provide information on the kernel's view of the cpu.<br><br>Ever wonder about specific process information? In the /proc interface, a directory is created for each process id that the kernel is currently running. <br><br><B>ls -al /proc/1</B> will provide all the information that the kernel is tracking for process 1 which is always the init process. For example, if you are curious what environment variables was passed to the init process when it started, <B>cat /proc/1/environ</B>.<br><br>If you don't have the <B>uname</B> application and you want to find the kernel version, <B>cat /proc/sys/kernel/osrelease</B>.<br><br>The /proc interface can be a useful method to query the kernel.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6178263</guid>
<pubDate>Tue, 04 Mar 2003 12:27:02 EDT</pubDate>
</item>

<item>
<title>Little Known Tips and Tricks...</title>
<link>http://www.dslreports.com/forum/remark,6178008</link>
<description><![CDATA[<A HREF="/useremail/u/521190"><b>dom6791</b></A> : I was just wondering if some of you more knowledgeable *nix users would share some of your lesser known tips and tricks with Linux? Not including the information listed in this forums FAQs.]]></description>
<guid isPermaLink="true">http://www.dslreports.com/forum/remark,6178008</guid>
<pubDate>Tue, 04 Mar 2003 11:50:00 EDT</pubDate>
</item>

</channel>
</rss>
