6,142 reputation
1722
bio website
location Seattle, WA
age
visits member for 2 years, 3 months
seen yesterday

I am a computer programmer. Knowledge representation and algorithmic complexity are my main interests.


Apr
11
comment How to determine eth0 gateway address when it is not the default gateway?
Interfaces don't have gateway addresses, netblocks do. A gateway address tells the kernel where to forward packets destined for some host on some network. If the address is associated with a given interface then that interface will be used, but the address is independent of the interface.
Apr
9
comment Why does parallel slow down after a while?
If you renice the parent process, all future spawned children will share that niceness value.
Apr
8
comment Why does parallel slow down after a while?
Use the renice command.
Mar
16
comment Terminating an infinite loop
@cirosantilli Yes, that's the reason. If a process handles the signal and quits, that's different than the process being terminated by an unhandled signal.
Mar
15
comment Terminating an infinite loop
@cirosantilli Done.
Mar
8
comment DHCP lease acquired , yet no ping, not even to default gateway
Please provide the complete output of netstat -rn and ifconfig.
Jan
22
comment Why doesn't setuid on /sbin/dhclient work as intended?
I'm assuming a C program which would call setreuid(), then execve().
Nov
7
comment Split tmux windows with same keys as in Emacs?
Have you read the man page for tmux? It should be obvious what to do. Unfortunately if you do it, then C-x stops working as a prefix key in Emacs because tmux will interpret it instead.
Oct
19
comment Mac OS X Darwin: how to reset admin password?
I advise buying an old installation DVD and doing a complete OS reinstall at your earliest convenience. I would not trust the existing installation to not be compromised in some fashion.
Sep
29
comment Linux: Write cache tuning
Which filesystem are you testing against? What kernel version are you using?
Sep
14
comment Debian machine makes repeated requests to DNS for <gateway_ip>.in-addr.arpa
That log entry says that .2 is trying to reverse resolve .1, not itself. Just ping'ing the router would be enough to generate such requests. netstat -r or traceroute would do the same.
Jun
18
comment perl one liner + how to replace any last IP address octets
Why do you need a Perl one-liner?
Jun
12
comment How do I trigger autocomplete without a tab key?
For some reason I didn't see the Ctrl button overlaying the text, so you could use that, I guess.
Jun
11
comment How do I trigger autocomplete without a tab key?
You don't, at least not to bash. Normally I would tell you to type Control-q A or Control-v A to get an A in this case but you don't seem to have a control key either. Pick Z or one of the easy symbols if A looks like something you can't live without.
May
12
comment How to disable caps-lock, without remapping or disabling it?
Please provide details as to what you tried, i.e. the exact xmodmap expressions. Without details we can't tell whether you knew what to do and did it wrong, or whether you did it right but the code failed for some other reason. Also give us the OS you're using because some have keycode processing that occurs below the X server level.
Apr
30
comment Removing all spaces, tabs, newlines, etc from a variable?
@magixx Thanks for the correction.
Apr
24
comment How to demonstrate invalid PID assumptions?
To end up killing the wrong process you need 1) a process that uses a PID file to die without removing the PID file, 2) the process not be restarted by systemd/init/launchd/whatever, which would put a new PID in the PID file, 3) 100,000 PIDs have been assigned so that PIDs start being reused, 4) a kill() system call directed at the PID of that old process while a new process is using the PID. If the user running the process isn't root, the odds of killing the wrong process decrease even further. There's no way to orchestrate these conditions easily on a live system.
Apr
9
comment I have a route to the network but from the traceroute output it doesn't leave the server
@depquid Yes, but 10.32.32.1 is being used as a gateway and it may be able to talk to 10.32.13.128/25 on another interface. There's no way to know whether it can from this table, but assuming that it can there's nothing wrong with the route.
Apr
4
comment Emacs: mode-local macro with dashes and dots
If you do regex searches using \w, dash and period are now going to be matched in buffers using the altered syntax table. Cursor motion commands will also be affected; forward-word will no longer stop before these characters. Similarly kill-word will delete more text than before. I think this behavior would be quite surprising and unpleasant in programming mode buffers, but in a text mode like HTML, I don't think it would cause much grief.
Apr
4
comment Wrong behavior of xargs
Shell variables do not maintain their values across different invocations of the shell, so what you're doing will never work. Try piping find's output to wc -l to count the lines of output.