Showing posts with label GNU/Linux. Show all posts
Showing posts with label GNU/Linux. Show all posts

Wednesday, October 19, 2022

Permanently set DNS in headless Debian or LXC/LXD container via CLI

 If you're like me and you've been through all those howto's that have you installing and using nmcli/resolvconf/network-manager and still don't have a permanent DNS, well you've come to the right place.

Again, I tried all that and then some. I even tried editing dhclient.conf and that didn't do anything either.

Forget installing whatever program that you don't need. 

All you need to do are three things.


1. Check if /etc/resolv.conf is a symlink to /run/systemd/resolve/stub-resolv.conf

    If it IS a symlink then ...

2. Delete the /etc/resolv.conf symlink and add a new /etc/resolv.conf

    rm /etc/resolv.conf; vi /etc/resolv.conf

    In the new /etc/resolv.conf add your nameserver

        nameserver 192.168.5.20

3. Restart your network or reboot.


The symlink is managed so anytime you edit the symlinked resolv.conf, the manager changes it back. But if you delete the symlink and create it again, the nameserver you add will be persistent.

Thursday, February 16, 2012

Changing mp3 file bpm/tempo for use with Mixxx to reduce slowing/bogging/sluggishness

Just had a good idea of minimizing cpu usage while using Mixxx. The best idea I came up with was to resample the mp3 to increase/decrease the tempo (w/o affecting pitch).

sox original.mp3 newfile.changedBPM.mp3 tempo 1.025

This will give it an increase of 2.5% where 1.1 would give 10%. and the opposite is 0.9 would give -10%.

However if you want the pitch to change as well, just replace tempo with speed. Now instead of Mixxx dealing with the BPM change and slowing things down, just get the files as close as possible to each other and play DJ w/o the slow down.

I use a netbook so it's not that powerful and whenever I hit the "key" option to keep the same pitch and do a sync to beatmatch...all hell breaks loose and I get random sluggishness. So by changing the files beforehand, this should reduce the calculations needed by Mixxx. Haven't tried it yet as I'm at work but crossing fingers!

Monday, February 14, 2011

Woot! Debian 6.0.0(Wheeze) is out and installed on my netbook!

So I had Ubuntu 10.04 LTS "installed" using wubi from Windows7. That was a pain in the ass and it often froze. Boy did I have to use the alt+sysreq+f and all other combos a lot to stop it from freezing. Had to do the a+s+reisub combo plenty of times too! But it was still half a year till the new Debian would be out so I stuck with it. Not that Ubuntu is bad...it just wasn't my flavor. In the past I've used Slackware (something like 3.5-7), Red Hat (4 - don't remember) so Ubuntu wasn't as in depth of an OS as the others since it's geared for newer linux users (yes I know it's based off of Debian but it really isn't anything like Debian). I like tinkering so Slackware was great. But yeah I installed Wheeze on the netbook and it worked like a charm. Only had 2 issues.

1st was that Windows 7 was detected during the install but not listed in Grub2 but that was easily remedied by doing update-grub (as seen here towards the bottom in the Errata section). That will look at your partition tables and reinstall grub2 with windows included.

2nd was getting UIM (Universal Input Method) to work properly. I got everything installed and started but it wouldn't respond to my hot keys or input Japanese! So after hours of searching, I figured it out. You have to change which input method your system uses! So if you have im-config or im-switch, use that and click on the radio for your input method. Mine for example was UIM so I chose that...otherwise if you use SCIM choose that, etc. After setting that, my hot keys worked and the Japanese input worked like a charm!

I have to say that I like it a whole lot better and it is much more stable than Ubuntu. I didn't however like Iceweasel too much since Coolpreviews didn't work with it...So I installed Firefox 4 beta and wow, that thing is pretty fast! It still uses a lot of memory but cpu usage is really low! And I have my coolpreviews back, although a few other addons don't work now. ugh. Anywhoo....I need to update my main amd64 laptop to wheeze soon and that should be fun backing up my system and then restoring everything to working order. After that, I won't be looking at Ubuntu again and no more updating every other day either! sheesh that was a pain.
Debian ftw!