Posted in Unix on November 10th, 2009 1 Comment »
upgraded from squeezebox center 7.1 to 7.4 today and my aac playback broke.
to fix, i had to add the following lines to my convert.conf file:
mov mp3 * *
# FB:{BITRATE=-B %B}
[faad] -w -f 2 $FILE$ | [lame] –resample 44100 –silent -q $QUALITY$ $BITRATE$ -x -r - -
mov wav * *
# F
[faad] -w -f 2 $FILE$
mp4 mp3 [...]
Posted in Unix on April 6th, 2009 No Comments »
while trying to upgrade my packages, i got caught with the following error:
Removing ghostscript …
Purging font configuration of gs…
No alternatives for ps2pdf.
dpkg: error processing ghostscript (–remove):
subprocess pre-removal script returned error exit status 1
Errors were encountered while processing:
ghostscript
E: Sub-process /usr/bin/dpkg returned an error code (1)
to solve it, i edited the following file:
/var/lib/dpkg/info$ sudo emacs ghostscript.prerm
by commenting [...]
Posted in Unix on January 28th, 2009 1 Comment »
so a couple of weeks ago, i decided to upgrade the hard drives in my server. previously, i had two 160 GB drives mirrored in a RAID 1 array. there were several partitions in the array.
after an impulse newegg buy (curse you and your sales newegg!), i had two 750 GB drives i endeavored to [...]
Posted in Mac OS X, Unix on January 28th, 2009 2 Comments »
i recently installed some massive hard drives in my server box. given all that space, i thought it’d be perfect to have the mac’s in my house all backup via time machine to those drives. here’s how i got things working.
enable sharing on the macs by opening the terminal and entering the command:
> defaults write [...]
Posted in Unix on December 30th, 2008 No Comments »
while replacing a hard drive in my server this weekend, I tried to install GRUB on the replacement hard drive:
> /usr/sbin/grub-install /dev/hda
only to receive the following error message:
/dev/hda does not have any corresponding BIOS drive.
this was strange, as I was certain that /dev/hda existed. after some googling, I found the solution:
> sudo /usr/sbin/grub-install –recheck /dev/hda
Posted in Unix on August 31st, 2008 No Comments »
to remove a user and their home directory, use:
sudo deluser -remove-home <user-name>
to remove all of their files on the server:
sudo deluser -remove-all-files <user-name>
Posted in Unix, Webserver on August 26th, 2008 No Comments »
to setup my server to use a static ip address i edited the file /etc/network/interfaces to include the lines:
iface eth0 inet static
name Ethernet LAN card
address 192.168.2.100
netmask 255.255.255.0
broadcast 192.168.2.255
network 192.168.2.0
gateway 192.168.2.1
of course, whomever provides you with your static IP address should also be giving you the appropriate information to fill in here.
Posted in Perl, Unix on May 13th, 2008 1 Comment »
let’s say you’ve got a string and you’d like to count the number of times some substring appears in it. let’s also assume that you’re lazy and you don’t want to leave your shell terminal to do it. fortunately, there’s an easy way to count string matches from the command-line using a perl one-liner. let’s [...]
Posted in SVN, Unix on February 27th, 2008 1 Comment »
i received the following error message while trying to build subversion the other day:
/usr/bin/ld: /home/ldavid/src/subversion-1.4.6/neon/src/.libs/libneon.a(ne_request.o): relocation R_X86_64_32 against `a local symbol’ can not be used when making a shared object; recompile with -fPIC
/home/ldavid/src/subversion-1.4.6/neon/src/.libs/libneon.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [subversion/libsvn_ra_dav/libsvn_ra_dav-1.la] Error 1
the solution i found:
first, add the following to [...]
Posted in Unix on February 27th, 2008 1 Comment »
if you don’t have a sudo account that doesn’t mean that you won’t be able to compile and install code from source. it turns out that all you need to do is set the prefix ./configure flag to a directory that you’ve got write-access to, and then you’re set to go. i found this extremely [...]