6,488 reputation
919
bio website taz.net.au/blog
location Australia
age 47
visits member for 3 years, 7 months
seen Dec 17 '13 at 2:57

Craig Sanders

http://taz.net.au/~cas/


Sep
30
comment List of 'if' switches anywhere?
type help test in your bash shell.
Sep
29
comment How to add Multiple Searches in AWK command
awk understands extended regexps, so for a pattern as simple as that you could write it as awk '/Jun|Jul|Aug/' or awk '/Ju[nl]|Aug/'
Sep
29
comment How to update an init script
would be interesting to see what happens in the script when run as user git. try editing the script and adding set -x somewhere near the start of the script (this does same thing as running with bash -x), and then sudo -u git -H -i /etc/init.d/gitlab start. my guess is that there's likely some permissions or ownership problem (e.g. files or dirs or sockets in ~gitlab owned by root rather than by user git)
Sep
29
comment Tune write disk cache flushing algorithm
33% is wildly optimistic. your read and write will chug along at a decent speed only until the buffers are full. then your read speed will be maximum of as fast as you can write (i.e. as fast as you can clear buffer space for incoming reads) but more likely a lot slower than that. the problem being that a lot of stop-start reads meaning that the reads will never get anywhere even close to max throughput and is more likely to result in slowdown due to rotational delays (waiting for the sector to come around again).
Sep
29
comment Tune write disk cache flushing algorithm
This seems to me to be a case of premature or misguided optimisation - and the best you can hope to achieve is to make sure that reading the source disk is continually stopping and starting (as small amounts of cache become free) rather than long sequential reads.
Sep
29
comment How to update an init script
what makes you think that the problem is due to replacing an init.d script rather than just bugs in the new version of the script? btw, stracing a shell script isn't usually very useful - try running it with bash -x instead. e.g. bash -x /etc/init.d/gitlab start
Sep
28
comment How do I fix the argument received from getopt?
+1 even though i strongly disagree that the getopts built-in is better than getopt from the util-linux package. /usr/bin/getopt supports --long options, built-in getopts doesn't. the real advantage of getopts over getopt is that getopts is part of the POSIX sh standard, and is available (nearly) everywhere, while getopt is not guaranteed to be installed. personally, i always use /usr/bin/getopt in my own scripts - for me --long option support worth the minor effort of installing it wherever i need it.
Sep
28
answered Is there any tool to view live statistics about a Radeon GPU?
Sep
28
revised Correct way of updating plugins for webapplications hosted on linux
deleted 1 characters in body
Sep
28
comment Correct way of updating plugins for webapplications hosted on linux
many web-hosting environments are sub-optimal, unless you (and your users) can avoid them entirely, you just do what you have to do to work within their flaws - which is why i gave you the pragmatic "use a tar file" answer. a server can be set up so that wordpress can overwrite its own scripts, but it doesn't have to be. well-run sites operated by people who care about security don't set it up that way.
Sep
28
revised Failure in the middle of a Debian upgrade
fixed unmount example
Sep
28
comment Failure in the middle of a Debian upgrade
you're welcome. please accept and/or upvote the answer if it helped solve your problem.
Sep
26
comment Is there a general rule for tracking an error?
some would consider this to be a bug in su. it shouldn't say "incorrect password". it should say "no, go away. don't ask why. i could tell you but then i'd have to kill you".
Sep
26
answered Correct way of updating plugins for webapplications hosted on linux
Sep
26
comment How to tell rsyslog to create log file if not there?
you mean, if rsyslog.conf has changed and there's a new log file defined? yes, it definitely will create and start writing to the new file on receiving a HUP...that's part of the point of it re-loading the config.
Sep
26
comment MySQL aborting during initial db installation
if you really need your dev box to be identical to your production box, i'd suggest running a clone of the production server in a VM.
Sep
26
comment MySQL aborting during initial db installation
third-party packages for debian (and other distros) are almost-universally awful. There are notable exceptions but, generally speaking, even when they're made by the developer of the software, they're rarely made with any real attempt at systems integration with the target distro and are far more often made with the attitude that 'our program is super-special and doesn't have to play nice with others'.
Sep
26
revised How to tell rsyslog to create log file if not there?
added 367 characters in body
Sep
26
answered How to tell rsyslog to create log file if not there?
Sep
26
comment Install single debian experimental packages?
IMO your best option would be to just switch to debian jessie aka testing, and apt-get install openbox (and related packages) to keep the same openbox-based UI. or use xfce. or maybe lxde.