Archive for the ‘linux’ Category
Finally I can talk to ubuntu
Yes, finally. finally finally finally.
Finally my internal mic works on my laptop (acer5520).
After pouring all my brains out on what the problem or fix could be, I finally resorted to installing the latest alsa drivers (1.0.19) from source and voila! Now I do not know if its the version difference or installing from source, which caused the miracle, (and neither do i care to know) the important thing is that it works. And so does my skype. Its a bit noisy thgouh and I have to tweak my volume levels.
The point to never forget is that now I don’t have to boot back to windows, ever
. Well, I may use xp on virtualbox, specially for preparing the resume (Oh resume! why aren’t thou in sexy latex?) after the sweet mishap of losing my job, I can easily delete my grub entry and eventually the win partition (a big
).
mpd (music player daemon/musicpd) and icecast2
http://wiki.archlinux.org/index.php/Streaming_With_Icecast_and_MPD
remember, no other audio output is required if your icecast server is running. the alsa output used in the link is just for fallback. if you do not want any output (audio) on the server itself, use only the shout output.
now, as it happened with me, may be you will encounter an error saying no audio device specified while playing music (i got this error with gmpc). if that’s the case, use mpc (cmd: mpc play).
depending on the buffer limit, the delay between the server and client might be upto 15 secs.
also, if you get “The file you requested could not be found” page on opening any streams, its true. you have fucked up somewhere, for instance, not keeping the user in the audio_output configuration as “source”, but “admin”, which was my admin user for icecast server
.
apt-p2p
Original link: http://debaday.debian.net/2008/11/09/apt-p2p-peer-to-peer-downloading-of-debian-packages/
<excerpt>
Apt-P2P:
Is faster at downloading from mirrors.
Uses much less memory and a little less CPU.
Can download almost all files (source files, Packages.bz2, etc…) from peers, not just .deb packages.
Works with only the information apt has, no need for other files.
Doesn’t require a new apt transport for communicating with apt.
Is more modular and easier to understand as it is based on existing technologies (e.g. twisted).
</excerpt>
Netbeans 6.1 and Java jdk6 (jdk 1.6)
If you are as unlucky as me you will find that if you try to use netbeans with jdk 6, you will be thrown a greyed blank window. Now, this happened to me in solaris but it does not necessarily depend upos the os.
The solution is:
export AWT_TOOLKIT=MToolkit
or you can create an executable with the following line: “AWT_TOOLKIT=MToolkit netbeans”, and use this executable to start netbeans.
mplayer and choppy fullscreen videos
many a times, specially while playing hd avis, my mplayer fullscreen sucks. it causes visual reverberations in the frames. sometimes the frames stuck, but mostly they just shiver like they have been caught murdering my entertainment. i figured out the remedy after trying smplayer. just add the option “-lavdopts skiploopfilter=all <or bidir>” as smplayer does.
but this actually degrades the quality of the video, as now some (or all) frames are not filtered to help in decoding the frames.
just going through the manual and trying various options gave me: lavdopts thread=2 (or more), especially if you have a multicore cpu. even if you don’t, this should help.
dwm dwm dwm dwm, dwm dwm dwm dwm!!
yes. this is the new mantra of my life. now mandu told me about this when probably last year. but then i was pretty satisfied with xfce (and i even am), and i did not want to change my loyalty. but now as i have a single gb ram’d desktop at my office (help!! office-admin!!), and i hate to carry my laptop (company provided) everyday to work, i thought that i could do better with something seeking as less mem as possible. you remember god only when in trouble.
getting initial helps from a blog, which resulted from a google for “dynamic window manager”, i was almost good to go. with a few good colors and shortcuts, now i almost cruise through my day without holding back even for a while, even when netbeans is running. netbeans? why netbeans if you want low mem apps? now that will be another blog entry.
quoting from suckless.org:
- dwm is only a single binary, and its source code is intended to never exceed 2000 SLOC.
- dwm is customized through editing its source code, which makes it extremely fast and secure…. you only have to learn C (at least editing header files).
- dwm reads from the standard input to print arbitrary status text (like the date, load, battery charge). That’s much simpler than larsremote, wmiir and what not…
some definitions, which might help:
tag == workspace/desktop.
rules == window specific rules, something for which you might use devilspie or kde’s capabilities
1<<TAG == bitmask for the tag. specifies a tag. simply putting a 3 (== (11)2 will cause both tags 1 and 2 to be called for.
some of my config.h comments:
———–
/*
in the rules section, keep isfloating false for most of the apps, as a floating window is always “on top” in default dwm.
*/
#define MODKEY Mod1Mask // Alt Key (or your first modifier)
#define WINKEY Mod4Mask // generally the win key.
static const char *audiomutecmd[] = { “amixer”, “set”, “Master”, “toggle”, NULL };
// the commands need to be given as each space separated list of words.
some links:
xmonad (since its based on dwm, the key shortcuts are the same, and some other basics too)
the blog
weird ssh error
got weird “unable to negotiate a key exchange” error. no good info on gooling.
tried sshd -ddd on the server side to enable debug mode for the daemon. on solaris it is /usr/lib/ssh/sshd.
found an error “no kex alg”, it meant my key for the host does not exist. used ssh-keygen -p -f <filename> and put the <filename> in /etc/ssh/. viola!
do you hate computer beeps in (x)ubuntu?
“rmmod pcspkr” can save you.
do a “modprobe pcspkr” to reload the module, if needed.
Bridging virtualbox >1.6.2 on ubuntu hardy
http://samiux.wordpress.com/2008/07/30/bridging-virtualbox-162-on-ubuntu-8041/
some xubuntu hacks (hardy) for acer aspire laptop
- multimedia keys: as simple as changing the keyboard layout to “acer laptop”
- usb mouse is not auto detected: type lsusb in any terminal each time you plugin a usb mouse
- external drives not writable (ntfs): install ntfs-config. type ntfs-config in any terminal. change the options in the gui.
- system doesn’t restart/shutdown: add ‘apm_poweroff=1′ to /etc/modules file. add ‘acpi=force apm=poweroff’ in your kernel line of the menu.lst (/boot/grub/menu.lst) to look like this – “kernel /boot/vmlinuz-2.6.24-19-generic root=/dev/sdA1 vga=773 ro acpi=force apm=power_off”
- vga=773 doesn’t work: add ‘vesafb’ to /etc/modules. comment ‘vesafb’ from /etc/modprobe.d/blacklist-framebuffer