नक्कारखाना

.. तूती भी बोलती है ।

Archive for the ‘solaris’ Category

Solaris Audio Mixer

without comments

http://sourceforge.net/projects/solmix

I could not find the usage anywhere so I had to look in the program itself.

solmix [ mute | [ [+|-] num ] ]

Written by Sudhanshu

December 24, 2008 at 12:55 pm

Posted in solaris

mpd in solaris

without comments

since i wrote about using icecast i am liable to also write about installing mpd now.

well, it wasnt simple. at least not for me. let’s take it step by step.

1. the first thing you will notice is that mpd’s configure utility is not able to find any audio devices. oops! at this point you will have to find out libao libraries for you system. the source install is pretty simple. you might also get some .pkg files through the net. i would have given the links but i did it way back. i a not sure but you might need a restart.
[update: since my libao is in /opt/csw, i say u can find it at blastwave.]

2. ao is disabled by default, so you will have to use ./configure –enable-ao –with-ao=/opt/csw  (/opt/csw is the prefix where ao is installed)

3. now for icecast. if you want it, first install the icecast server from source. also install shout libraries (available from the icecast.org), again from source. everything should work smoothly.

4. but even now the mpd configure wont detect shout libs. just copy the shout.pc from the shout source directory to /usr/lib/pkgconfig/. also copy the include/shout from your shout source dir to /opt/csw/include (this is definitely going to be included because you gave –with-ao=/opt/csw)

5. if even now the shout support is disabled and you see something like “gnome-config not found” in the configure output, just open configure file, find [[[if test "$PKGCONFIG" != "no" && `$PKGCONFIG --exists shout`]]], and change the “&&” to “||”. basically your pkg-config is giving errors in finding shout. but since its already there, you can skip the check.

6. now everything should work. do a make and a make install. enjoy madi!!

7. install mpc and ncmpc. i tried gmpc but failed. currently i have moved to foobar2k on wine instead of mpd, but if i install gmpc some day, will definitely write about it. ncmpc is easily available as .pkg (blastwave); its a bit old, but serves the purpose.

Written by Sudhanshu

December 11, 2008 at 6:02 pm

Posted in solaris

Solaris add swap file

without comments

Well the process is as simple as using ls to list files. But even there, I can screw up.

1. mkfile 1024m <filename>
    Units for the size can be kilobytes (k), blocks (b), or megabytes (m).
2. swap -a <complete file path>
3. swap -l (to list the swaps)

Now the problem is I created the file using my local user and was trying to add it as swap. I kept on getting the following error:
It must be a block device or a regular file with the “save user text on execution” bit set.

Finally, after half an hour of googling and leading nowhere, I decided to do everything as root. Voila!

So the steps are:
1. mkfile 1024m <filename>     (as root)
    Units for the size can be kilobytes (k), blocks (b), or megabytes (m).
2. swap -a <complete file path>     (as root)
3. swap -l (to list the swaps)     (as root)

Written by Sudhanshu

November 27, 2008 at 7:05 pm

Posted in solaris

Netbeans 6.1 and Java jdk6 (jdk 1.6)

without comments

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.

Written by Sudhanshu

November 19, 2008 at 6:48 pm

Posted in linux, solaris

Install sudo in solaris

with 2 comments

http://sysinfo.bascomp.org/2007/09/25/installing-sudo-on-solaris/

you can also install it with pkg-get (blastwave).

Written by Sudhanshu

November 14, 2008 at 3:22 pm

Posted in solaris

Perl Errors in Solaris

without comments

1. ld.so.1: perl: fatal: relocation error: file symbol Perl_Gthr_key_ptr: referenced symbol not found Killed
         — this basically means that your perl executable is using modules from a different perl version. Change your PERL5LIB to use the corresponding libs.

2. Base class package “Class::Accessor::Fast” is empty.
         — might be that you don’t have this package installed. Install it using “perl -MCPAN -e `install Class::Accessor::Fast`”. If you have multiple perl executables (diferent versions), use the full path.. for instance, “/opt/csw/bin/perl -MCPAN -e `install Class::Accessor::Fast`”.

3. Perl lib version doesn’t match executable version at Config.pm
         — again there is a conflict between your perl executable versions. Be sure which one do you want to use.

Written by Sudhanshu

November 14, 2008 at 12:42 pm

Posted in solaris

solaris home end delete insert pageup pagedown keys

without comments

i hated solaris. even now i don’t like it completely. but it has its benefits, the most likeable one being the presence of various devs you might need for building the sources. the most annoying thing is not being able to use many of the accessory keys. even tweaking inputrc doesn’t help. solution?

1. install vim. your editor will be fine atleast with almost all the keys working, and no vi nuances.
2. still the terms don’t work. sometimes you might be lucky enough to get keys working through inputrc. but then they get screwed in vim, displaying escape/control sequences instead of what they are supposed to do.
3. use mrxvt. it provides you options to set the keys only for the term (and not for any other internal applications). change your base terminal to xterm in .mrxvtrc. probably somethings will start to work. if no use the option linuxHomeEndKeys.
4. if your delete key does not work with any sequence, use ^’. if that too does not work, use ^d (ctrl-d). beware: it will cause your terminal to exit if there are no characters on the current line.

Written by Sudhanshu

October 19, 2008 at 8:38 pm

Posted in solaris

dwm dwm dwm dwm, dwm dwm dwm dwm!!

without comments

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

Written by Sudhanshu

October 19, 2008 at 8:15 pm

Posted in linux, solaris

weird ssh error

without comments

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!

Written by Sudhanshu

September 26, 2008 at 2:28 pm

Posted in linux, solaris

how solaris disk device names work

without comments

http://initialprogramload.blogspot.com/2008/07/how-solaris-disk-device-names-work.html?cid=e6997

Written by Sudhanshu

September 15, 2008 at 2:04 pm

Posted in solaris