I leave notes here that I find particularly worth remembering myself.
-
Remove unwanted locales on Ubuntu / Debian
Please remember that this is not supported by the debian package manager and can break the system badly. I just read this while executing localpurge and stopped cold. The description said that the package manager would not know about it and strange effects could happen, the only way to fix it would be to have to reinstall all Debian packages that provide these locales. I'm really dependent on this server, it needs to run flawlessly, so I must look for another Debian compliant way, just wanted to post this here, to save people that time installing this in the first place. Filed under "don't break Debian"Posted 10-21-2020 at 03:34 AM by browny_amiga -
USB stick with Ubuntu Live system doesn't boot - why?
Quote:THANK YOU! THANK YOU1 I'd been beating my head against the monitor and trying *every* version of creating an Ubuntu boot usb drive. You were *absolutely* right that the "small print": needs to be set up as an installable drive is totally useless without some of idea of *how* one makes an installable drive. I followed your steps here and it worked like a charm.Posted 11-21-2012 at 04:54 AM by bittner -
USB stick with Ubuntu Live system doesn't boot - why?
THANK YOU! THANK YOU1 I'd been beating my head against the monitor and trying *every* version of creating an Ubuntu boot usb drive. You were *absolutely* right that the "small print": needs to be set up as an installable drive is totally useless without some of idea of *how* one makes an installable drive. I followed your steps here and it worked like a charm.Posted 11-20-2012 at 08:03 AM by drkitty -
USB stick with Ubuntu Live system doesn't boot - why?
Quote:I just formatted removable disk as fat32 boot from Ubuntu live. Reboot to physicaly remove thumb drive and return to 'Try' option before you insert disk into usb or slot to mount file system or ubuntu will ask to boot from serial drive2. From System Administration choose Create Boot Disk, format and set rw space to allow room for updates. First attempt gave disk full error.Posted 04-16-2012 at 07:21 AM by bittner -
USB stick with Ubuntu Live system doesn't boot - why?
I just formatted removable disk as fat32 boot from Ubuntu live. Reboot to physicaly remove thumb drive and return to 'Try' option before you insert disk into usb or slot to mount file system or ubuntu will ask to boot from serial drive2. From System Administration choose Create Boot Disk, format and set rw space to allow room for updates. First attempt gave disk full error.Posted 01-21-2011 at 02:39 PM by grizlbr -
Shortest command to calculate the sum of a column of output
Calculate using Bash when bc is not installed
A much better alternative to bc than using a lengthy for loop is using Bash's calculation capability directly. Interestingly, I've figured out, there are two ways of assigning a value to a variable this way:- (( A=1+1 ))
- A=$(( 1+1 ))
Code:((SUM=$(dpkg-deb -c mypackage.deb | sed -e 's/.*root\s*//' -e 's/\s*2010-.*$//' | xargs | tr ' ' +)))
Code:SUM=$(($(dpkg-deb -c mypackage.deb | sed -e 's/.*root\s*//' -e 's/\s*2010-.*$//' | xargs | tr ' ' +)))
Posted 08-25-2010 at 03:12 AM by bittner -
Howto build your own Debian repository
"generate" silently fails sometimes (workaround)
Sometimes, for some reason I have not yet fully figured out apt-ftparchive generate puts old (probably cached) data into the Packages file. You only note this problem when, e.g., the .deb file size has changed and the old size doesn't match the new size anymore. In this special case apt-get will then complain:
Code:E: Failed to fetch http://.... Size mismatch
Code:$ cd /home/bittner/Development/debian/mirror $ apt-ftparchive -c personal-archive.conf packages \ pool/personal/main > dists/personal/main/binary-i386/Packages $ apt-ftparchive -c personal-archive.conf release \ dists/personal > dists/personal/Release
Posted 08-06-2010 at 08:22 AM by bittner -
Shortest command to calculate the sum of a column of output
Usually, bc should be installed on your Debian system. If you don't have it you could simply use a for loop that's built into bash:
Code:SUM=0; for i in $(dpkg-deb -c mypackage.deb | sed -e 's/.*root\s*//' -e 's/\s*2010-.*$//' | xargs | tr ' ' +); do SUM=$(($SUM+$i)); done; echo $SUM
Code:NUMBERS=$(dpkg-deb -c mypackage.deb | sed -e 's/.*root\s*//' -e 's/\s*2010-.*$//' | xargs | tr ' ' +) SUM=0; for i in $NUMBERS; do SUM=$(($SUM + $i)); done echo $SUM
Posted 06-02-2010 at 06:57 AM by bittner