Hot answers tagged


Try using the -t option to ssh ssh -t root@my.machine screen "tail -f /var/log/messages" From man ssh -t Force pseudo-tty allocation. This can be used to execute arbi- trary screen-based programs on a remote machine, which can be very useful, e.g., when implementing menu services. Multiple -t options force tty allocation, ...


My problem is not the same as can't type lower cased e in amazon ec2 (Amazon Linux), but similar. After checking /etc/inputrc and finding nothing out of the ordinary, I remembered that I did do some keybinding in the /etc/bash.bashrc. This was already there for a very long time and worked flawlessly, though. Why would it make problems now? I found out ...


iftop is cool and lightweight. ntop is even cooler but web-based and uses a daemon.


Actually, a typical invocation of sudo does not read the password from stdin at all. Instead, sudo will directly access the controlling terminal (a tty or pty, via the /dev/tty special file) and output the prompt and read characters directly. This can be seen in the tgetpass.c file in the sudo source. There are a few other scenarios: If an askpass program ...


maybe they use tail -f on the access log?


I believe this is not so much about man itself but rather about your pager of choice (PAGER environment variable) combined with the terminal in use. I'm guessing your pager is probably less (typical default pager nowadays and fits with the description). less has an option -X that may get you a behavior along the lines of what you're looking for. -X or -...


Holding down the Ctrl-Alt while dragging the left mouse button.


which will search your path for the arguments you supply, it's found on just about any BSD or SysV UNIX moriarty:~ dave$ which bash true false /bin/bash /usr/bin/true /usr/bin/false


$ find /path/to/folder -type f -delete



You should be able to find out what killed your process by looking at the output of the dmesg command; or at the logfiles /var/log/kern.log, /var/log/messages, or /var/log/syslog. There are a number of things that can cause a process to be summarily killed: If it exceeds the hard ulimit for various memory or cpu usage types that you can examine using ...


You can use: ssh root@host screen -m -d "tail -f /var/log/messages" That starts a detached screen with a command running on it. -m causes screen to ignore the $STY environment variable. With "screen -m" creation of a new session is enforced, regardless whether screen is called from within another screen session or ...


top on MacOS X does support sorting, at least: O<skey> Set secondary sort key to <skey> (see o<key>). o<key> Set primary sort key to <key>: [+-]{command|cpu|pid |prt|reg|rprvt|rshrd|rsize|th|time|uid|username|vprvt |vsize}.


su - username is interpreted by your su to mean "run username's shell as an interactive login shell" su username - is interpreted by your su to mean "run the following non-interactive command (-) as username" the latter only worked at all because: your su passes trailing arguments to sh for parsing sh takes - to mean "run as a login shell (read /etc/profile,...


I'm working on porting htop to OSX. The repo is here (more active fork here, and can be installed via brew install htop) I'm currently trying to work out what to do about the licensing clash between Apple's libtop (APSL) and htop (GPL). There's probably not much more programming to do on it - but I may have to re-implement the bits of libtop I need. If ...


IPTraf is another common real-time bandwidth monitor on Linux IPTraf-ng is a updated fork of IPTraf with ipv6 support


$ touch {a,b,c,"white space"}.sample $ ls *.sample a.sample c.sample b.sample white space.sample $ for SAMPLE in *.sample; do mv -v "$SAMPLE" "${SAMPLE%.sample}"; done a.sample -> a b.sample -> b c.sample -> c white space.sample -> white space Edit: Also see ${parameter#word}, which deletes word from the front of parameter: $ ...


Okay, I found the answer after some googling. Apparently, LESSCHARSET needs to be set like this: export LESSCHARSET=utf-8 Now less works fine for me.

16 when using Mac OS X


This is what the 'screen' utility was invented for. Although I've used it mainly on Linux, there's absolutely no reason a port for your OS couldn't exist. It's part of the gnu tool set, and I haven't found a port, but one probably exists (or could).


You can modify .screenrc to allow mouse-based scrollback:


You should check out Windows Powershell. You could also try Cygwin if you're partial to Linux.


Or even something like logstalgia ;-)


[Update: As of Mac OS X Mountain Lion 10.8, Terminal supports the Backtab escape sequence, eliminating this issue.] The version(s?) of nano on those servers sometimes sends a Backtab (ESC [ Z) sequence when moving the cursor left by one character, but Terminal doesn't support this sequence, so nano thinks the cursor has moved when it hasn't and its idea ...


You could try using the "screen" command. This will allow you to run a multiuser session which 2 users can connect and share. First you'll need to set the suid bit. screen comes with it turned off, and it is necessary for multiuser mode: sudo chmod +s /usr/bin/screen sudo chmod 755 /var/run/screen The first user connect, running screen -S shared The "-...


use this: rsync -a /source /destination Alternatively, you can get more details with a few other flags like -v or --progress.


This looks absolutely puzzling to me. Either it should use some DNS name or IP address. I checked the last.c file also but I still can't find why it is not showing anything. Probably given some time, I can figure out the part about int dns_lookup(char *result, int size, int useip, int32_t *a) 307 { 308 struct sockaddr_in sin; 309 struct ...

Only top voted, non community-wiki answers of a minimum length are eligible