Reputation
1,437
Top tag
Next privilege 2,000 Rep.
Edit questions and answers
Badges
6 16
Newest
 Yearling
Impact
~42k people reached

  • 0 posts edited
  • 0 helpful flags
  • 19 votes cast
Jan
29
comment Any disk encryption that locks itself for some time after a number of failed attempts?
Of course, a determined hacker can divide your iter-time by the number of computer's he's willing to expend on hacking you - if you have iter-time set to 60000, and he has 1000 computers to spend on hacking you, that's the same as if you set iter-time to 60, so don't assume you can use a 4 character alphanumeric password in the belief it would take him years to crack it.
Jan
28
comment Can signal be ignored (lost)?
Did you mean to write "A signal is guaranteed to be delivered" since you went on to describe some of the ways in which the signal would not be delivered (i.e. process died before it was received, or signals were coalesced)?
Jan
20
comment How to represent date format in '2015120' in Linux shell?
out of curiousity, does he zero pad days? Is Feb 1st written as 201521 or 2015201?
Jan
13
comment Is it good to have multiple version of Linux Kernel?
The other option is to have enough server redundancy that you don't care what happens to any particular server, if it fails to boot after an update, you just deploy a new server and add it back to the server pool. Harder to do if your clients are logged in locally, but generally easy to do if it's providing some service to users and it takes a lot of the stress out of system updates.
Dec
29
comment Move file but only if it's closed
@JohnWHSmith - That's normally true if moving the file within the same filesystem, if he moves the file to a new filesystem before the writer has finished writing to it, he'll lose some data.
Nov
26
comment Can I use my original GPG key even though I've re-installed Linux?
How do you securely erase a USB stick? It'd be better to store it on an encrypted filesystem.
Oct
24
comment Exclude one pattern from glob match
@jbarker2160 - that's not really a regular expression, it's more commonly called a glob (or filename pattern), which is more or less a subset of a regular expression - see the pattern matching section of the bash manpage for details. His pattern foo.*[^org] will match any filename that begins with foo. with one or more characters after the dot where the last character is not o, r, or g. So it would match foo.orb, but not foo.org or foo.or or foo.o. GlennJackman's answer shows how to enable extended pattern matching features to negate a match.
Sep
6
comment Remove all files/directories except for one file
If it's a large file on a separate filesystem from /tmp and you're trying to remove everything from the root of the filesystem down, then moving it somewhere safe may not be an option.
Jun
26
awarded  Yearling
Jun
20
comment Using Perl to count the number of scientific numbers in a file
This would give incorrect results if a line happened to contain both a number and some other string. The answer above that uses grep's -o option to output only matches is more correct.
Jun
17
awarded  Nice Question
Apr
23
comment Is there an alternative to the `which` command?
If your shell or keyboard doesn't support "[]" (I think ash does), you can replace [ -x $dir/$COMMAND ] with test -x $dir/$COMMAND (test is a bash/ash built-in, and may also be available as a standalone executable
Apr
23
answered Is there an alternative to the `which` command?
Mar
29
awarded  Nice Answer
Mar
29
comment What is the best way to add a user to the sudoer group?
And, visudo only protects you from syntactical errors - it's still possible to lock yourself out of the system with a bad sudoers configuration. So, you should still know how to get root without sudo. I usually edit /etc/sudoers with vi instead of visudo, write the file, and test my sudo access before exiting vi. That way I can revert my changes if it doesn't work. This doesn't work with visudo since it edits a temp file. Though these days it's not much of an issue since nearly all of my servers are managed by Puppet, including the sudoers file.
Mar
29
comment ssh-copy-id hangs with 8192-bit key
For completeness, I tested with a 16384 bit key (the max key size for my version of ssh) and it worked fine too. Took a long time (5 minutes or so) to create that 16384 bit key and has a noticeable 2 or 3 second delay when authenticating to the remote host.
Mar
29
comment ssh-copy-id hangs with 8192-bit key
Works for me with an 8192 bit key and Linux client and server: OpenSSH_6.0p1 Debian-3ubuntu1.1, OpenSSL 1.0.1c 10 May 2012.
Mar
28
revised Sudoers for one day per week?
add comment about restrictng access to prod servers
Mar
28
answered Sudoers for one day per week?
Mar
28
comment Particular site is not working on Ubuntu 12.04
@Graeme - If an alternate DNS server solves his problem, he can edit the resolvconf config to hardcode the DNS server.