title: How to extend an ext3 partition over LVM inside a file (virtual machine)?

text: I need to extend the root partition of a virtual machine (VM) using LVM (Logical Volume Manager). I can afford a few minutes of downtime so a VM shutdown/reboot is fine. The virtual hard disk is in **qcow2** format but I can translate it to a **raw** format easily if it helps. Search engines did not help that much because answers usually refer to using a LVM partition to host the virtual hard disk, here the LVM partition is inside the virtual hard disk which is a simple file. The virtual machine is running with linux-kvm and must stay bootable after the operation.


title: Does Solaris have an equivalent to /etc/ld.so.conf?

text: I compiled a package for Solaris 11 Express that has some library dependencies, which I also compiled from source and installed in the usual /usr/local. (And Solaris doesn't even _have_ /usr/local pre-created!) So, my program runs correctly, but I have to run it with               LD_LIBRARY_PATH=/usr/local/lib ./myprogram      or it complains that it couldn't find libsomething.so. How do I include /usr/local/lib in the library search path, system-wide? Linux has /etc/ld.so.conf -- Solaris doesn't.


title: How to setup Git server on Linux Container in Debian

text: I have a LXC container on my Debian system. I want to setup a public Git server on it so that it's accessible to other people. How can I do this? ### UPDATE #1 Link to `apache2.conf`: http://pastebin.com/Nvh4SsSH.


title: How to stop `apt-get` complaining about unmet dependencies?

text: I have been installing some applications onto my Debian system. Now there are some that have dependencies that I do not want installed with the applications at the moment. I have managed this by using `dpkg` in some cases. The installed applications work fine without them at the moment. But now, every time I use `apt-get`, it complains about unmet dependencies. How do I cheat `apt-get` into thinking that all dependencies (2-3) are installed? Is there some file I can edit?


title: Tar up all PDFs in a directory, retaining directory structure

text: I'm trying to create a compressed tarball that contains all PDF files that exist in one of my directories. The directory structure needs to be retained. Empty directories are not needed, but I really don't care if they're there. For example, say I had a directory that looked like this:               dir     dir/subdir1     dir/subdir1/subsubdir1/song.mp3     dir/subdir2     dir/subdir2/subsubdir1     dir/subdir2/subsubdir1/document.pdf     dir/subdir2/subsubdir1/another-song.mp3     dir/subdir2/subsubdir1/top-ten-movies.txt     dir/subdir3     dir/subdir3/another-document.pdf      After running the command, I'd like to have `dir.tar.gz` contain this:               dir     dir/subdir2     dir/subdir2/subsubdir1     dir/subdir2/subsubdir1/document.pdf     dir/subdir3     dir/subdir3/another-document.pdf      Possible?


title: Beaglebone Black Device Tree for LCD4 cape

text: The device tree for LCD4 cape is located at /lib/firmware/BB-BONE- LCD4-01-00A1.dts When I looked into it, the declaration of those GPIO buttons confuse me. There are five buttons according to schematic revision A1 here link, none of them are mapped to GPIO0_3, which is UART2. But in the dts file, GPIO0_3(on P9_21) is used as a button.               bone_lcd4_cape_keys_00A2_pins: pinmux_bone_lcd4_cape_keys_00A2_pins {                     pinctrl-single,pins = <                         0x040 0x2f  /* gpmc_a0.gpio1_16, INPUT | PULLDIS | MODE7 */                         0x044 0x2f  /* gpmc_a1.gpio1_17, INPUT | PULLDIS | MODE7 */                         0x04c 0x2f  /* gpmc_a3.gpio1_19, INPUT | PULLDIS | MODE7 */                         0x154 0x2f  /* P9_21 spi0_d0.gpio0_3 INPUT | PULLDIS | MODE7 */                     >;                 };      Assume this is an error, I tried to disable LCD4 cape on boot up and start my own edited and compiled dts for LCD in **uEnv.txt** like this:               optargs=quiet capemgr.disable_partno=BB-BONELT-HDMI,BB-BONELT-HDMIN,BB-BONE-LCD4-01 capemgr.enable_partno=myNewCape      myNewCape.dtbo is located in `/lbi/firmware` and compiled from `myNewCape.dts` without errors. Basically I commented out all GPIO buttons and key group definition. It didn't work. This screen is clearly disabled due to `capemgr.disable_partno=BB-BONE-LCD4-01` but it never shows anything even `capemgr.enable_partno=myNewCape` is there.


title: No output produced when using winFF

text: I am using winFF in Ubuntu 10.04. WinFF is a graphical frontend to ffmpeg. Typically, after selecting a file in WinFF, setting my conversion settings and pressing the "Convert" button, a console appears with output from the conversion process and prompts requesting permission to continue. However, now, when I press convert, I only see a blank console with a command prompt such as:               oneat@oneat-desktop:~$      I thought I had misconfigured something, but I reinstalled everything but problem continues. Could you help me ? In general console output still works, since I see output when I run the following script:               #!/bin/sh     echo -n "\033]0; Converting _quot;LIKE A G6_quot; (OFFICIAL) FAR EAST MOVEMENT (FM) feat (1/1)\007"     /usr/bin/ffmpeg -i "/home/oneat/dwhelper/_quot;LIKE A G6_quot; (OFFICIAL) FAR EAST MOVEMENT (FM) feat.flv" -acodec libmp3lame -vcodec msmpeg4 -ab 192kb -b 1000kb -s 640x480 -ar 44100 "/home/oneat/_quot;LIKE A G6_quot; (OFFICIAL) FAR EAST MOVEMENT (FM) feat.avi"     read -p "Press Enter to Continue" dumbyvar     rm "/home/oneat/.winff/ff110111193250.sh"


title: Network interface eth0 not up at start on Debian 6

text: I have Debian 6.0. In my interfaces file (`/etc/network/interfaces`) I have the following lines:               auto eth0     iface eth0 inet static     address 192.168.0.8     netmask 255.255.255.0     gateway 192.168.0.1      Everytime I start the computer, `eth0` is not working. When I enter `ifconfig -a`, `eth0` is not "up" and "running". I have to enter:                ifconfig eth0 up      /etc/init.d/networking restart      And then it works. How do I have to change the config in order to have a working `eth0` in the beginning?


title: A simple hierarchical task list (that lets you cross out tasks) for linux in the Ubuntu repositories?

text: I just spent way too much time looking for this. Treeline is very close, but it doesn't allow marking a task as done with a single key press. It's a powerful data organizer and one has to change manually defined data types to achieve that. I'm looking for something simple: a list of tasks that can be organized into a tree that allows adding children, siblings and moving of items and marking them as done (ideally through keyboard shortcuts).


title: grep: regex only for match anything between parenthesis

text: How do I match word only between parenthesis Input : `this is (test.com)` Desire Output : `test.com`


title: Convert a number of seconds elapsed to date from arbitrary start date

text: I want to convert a particular amount of seconds to a date. In my case the it's the number of seconds elapsed since 1st of January 0001. If it were for seconds elapsed from epoch it would be easy: `$ date -r nr_of_seconds`. It would be awesome if there was a way of telling `date` to start at a particular date. Is there such an option (the `-v` option almost does what I need, ... I think)? I'm on a Mac.


title: Changing file permissions problem

text: A few hours earlier I bought a beaglebone (Ångström installed) and now I am trying to add nameserver 8.8.8.8 (google DNS) to /etc/resolv.conf. However when I open it with vim and try to add my nameserver, it gives me E21: cannot make changes, 'modifiable' is off. I changed permissions via chmod. (chmod u+rx /etc/resolv.conf and also tried chmod 777 /etc/resolv.conf) But nothing changed. Then I tried :set modifiable :set write This time I can change but still getting: E382: Cannot write, 'buftype' option is set error. What should I do? Regards


title: Kill TIME_WAIT sockets immediately?

text: Is there anyway to kill those `TIME_WAIT` sockets immediately ? e.g output of netstat:               tcp        0      0 127.0.0.1:8080          127.0.0.1:41500         TIME_WAIT   -                        tcp        0      0 127.0.0.1:8080          127.0.0.1:41501         TIME_WAIT   -


title: Is there a way to disable a plasmoid toolbox that pops up while mouse is over the widget/plasmoid?

text: When you hover any plasmoid, a vertical toolbox appears to the left. The toolbox contains the resize, refresh, settings and remove buttons. Is there a way to remove this small panel appearing on every mouse over or at least change the event on which it appears (eg. ctrl+right click). Right click offers the remove and settings options, but not refresh and resizing.


title: issue installing fedora 19

text: I'm sorry I know this is not the place but I'm kinda dead in the water here. So I'm completely new to Linux an I wanted to install Fedora 19 with my Windows 7 (dual boot) but when I go through the installation process it only shows my harddrive (not partitions) and says that there is 37 gig available for u an 17 mb available for us and says that there is not enough space on my hard drive. I have a 500 gig hard drive and three ntfs partitions with a LOT of free space should i resize one partition and leave the free space unallocated and then try to install fedora?


title: Current environmental variables of a process

text: This question relates to this answer. Is it possible to get the current (not initial) environmental variables of a process by making a child process and checking its initial environmental variables? The idea is that the initial environment of a child process is inherited from the current environment of the parent.


title: Unable to login due to invalid screen resolution

text: I changed the screen resolution on Ubuntu 12.08 using the GUI, but I think I've changed it to an unsupported resolution, and now the system logs me out immediately after I login. I tried using `xrandr` to fix it, but haven't had any progress yet. I can log in with the guest account though What can I do to fix this?


title: error while compiling ffmpeg: gcc is unable to create an executable file

text: When I run the `./configure` command in ffmpeg source directory I get this error:               gcc is unable to create an executable file. If gcc is a cross-compiler, use the --enable-cross-compile option. Only do this if you know what cross compiling means. C compiler test failed.          If you think configure made a mistake, make sure you are using the latest version from Git.  If the latest version fails, report the problem to the ffmpeg-user@ffmpeg.org mailing list or IRC #ffmpeg on irc.freenode.net. Include the log file "config.log" produced by configure as this will help solving the problem.      in config.log:               check_ld cc     check_cc     BEGIN /tmp/ffconf.xECiIX7z.c         1   int main(void){ return 0; }     END /tmp/ffconf.xECiIX7z.c     gcc -c -o /tmp/ffconf.xsCaoMWN.o /tmp/ffconf.xECiIX7z.c     gcc -o /tmp/ffconf.ApzYq7NQ /tmp/ffconf.xsCaoMWN.o     /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crt1.o: In function `_start':     (.text+0x12): undefined reference to `__libc_csu_fini'     /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crt1.o: In function `_start':     (.text+0x19): undefined reference to `__libc_csu_init'     collect2: ld returned 1 exit status     C compiler test failed.      What's wrong? What should I do?


title: Merge two command results to one line when redirecting stdout

text: In a cron script I want to log CPU temperatures in the format               [datetime] temp      using `date` and `acpi -t`. How can I redirect (`>>`) these two commands to a single line in the log file?


title: IPv6 - how to force traffic destinated for same system but another interface to pass through the wireless network?

text: I want to perform some IPv6 stress testing (file transfer, flooding, Neighbor Discovery, etc) on wireless routers using a system which has two network interface cards. However, all traffic goes over the loopback device. How do I force IPv6 traffic destinated for the same system (but another NIC) to pass through the actual wireless network / router. Disabling the loopback interface seems to be a rough step, as linux distributions cannot work bugless without it. I guess, we need some routing rules for sending and receiving such packets. I am running right now the latest ubuntu, but solutions should be compatible to other distros, if possible.


title: Making zsh default shell without root access

text: I am using my school's computers and would like to use `zsh` instead of `bash`. I'd like to make it default, but I cannot run a command such as `$ chsh -s $(which zsh)` because I don't have admin privileges. Is there a way I can put something in my `.bashrc` or something that automatically calls `zsh` when it opens as a workaround? To clarify, `zsh` is already installed. Thanks for your help.


title: Unable to play protected (DRM) content on Chrome (Linux Mint 17)

text: I upgraded to Linux Mint 17 a couple weeks ago. Prior to that, I was running on LM 16 and had an issue playing protected content on Google Chrome. I fixed that issue after installing hal and disabling Chrome's flash player in favour of Adobe's. But since I'm on LM 17, that problem reared its ugly head again. I recently installed hal and since Chrome no longer gave me the option to disable/enable specific flash plug-ins, I renamed Adobe's to libpepflashplayer and moved it to opt/google/chrome/PepperFlash. Unfortunately, the problem still persists and it's worse now since I know get the notice "Could not load Shockwave Flash." Linux Mint 17 (64) Google Chrome Version 35.0.1916.114 Sites attempted to access: Espn3.com, Video.adultswim.com/watch-live Also, I can't get this video (http://drmtest2.adobe.com:8080/Content/anonymous.f4v) to run in Adobe's demo video player (http://drmtest2.adobe.com:8080/SVP/SampleVideoPlayer_FP.html). Since swaping Chrome's built-in plug in for Adobe's, I can't make use of the site due to the plug-in crashing.


title: NFS, CIFS, and permissions

text: If you copy files from an NFS mount to a CIFS mount on a different server, will the permissions be retained? I am a little unclear how the file permissions work in these 2 filesystems. It seems like that for CIFS, generally the permissions are set by the CIFS server, and they are identical to the local filesystem permissions on that server, whereas with NFS, generally the permissions are determined by a combination of client side mount options, and what is allowable in the exports config (/etc/exports). Can someone explain this a bit please?


title: To assign variable from a file separated by delimiter

text: I have a text file with datas as below separated by delimiter:               1000:Tom:user1     1002:Jerry:user2     1003:Victor:user3     1004:Jason:user4      I need to run a while loop (any loop) to fetch details from first line and assign variable as below:               uid:1000     username:Tom     userid:user1      I know we can use awk but I am not so much expert in using awk and could not find much resolution. If there is other way to do so, please share that to me. This script should be able to collect details till the end of file "data". I can do this part once I am able to do for the first line.


title: How can I execute local script on remote machine and include arguments?

text: I have written a script that runs fine when executed locally:               ./sysMole -time Aug 18 18      The arguments **"-time"** , **"Aug"** , **"18"** , and **"18"** are successfully passed on to the script. Now, this script is designed to be executed on a remote machine but, from a local directory on the local machine. Example:               ssh root@remoteServer "bash -s" < /var/www/html/ops1/sysMole      That also works fine. But the problem arises when I try to include those aforementioned arguments **(-time Aug 18 18)** , for example:               ssh root@remoteServer "bash -s" < /var/www/html/ops1/sysMole -time Aug 18 18      After running that script I get the following error:               bash: cannot set terminal process group (-1): Invalid argument     bash: no job control in this shell      Please tell me what I'm doing wrong, this greatly frustrating. I've looked in multiple places for the answers. Any help is greatly appreciated.


title: How searching works in GNOME 3.8?

text: How does searching work in Gnome 3.8.2? Why when I search 'power' (Press Super key and type 'power' one-by-one) I get **LibreOffice Impress**? And 'po' returns **Document Viewer** , **Rhythmbox** , **SElinux Troubleshooter** , **OpenJDK Policy Tool** , **Software** , **Automatic Bug Reporting Tool** , even **Mouse & Touchpad** and **Notifications** comes before **Power** , why is this?


title: How can I update my dynamic DNS under OpenWRT?

text: I have an OpenWrt 10.03, and I need to update my dynamic DNS account (e.g., OpenDNS or DYNDNS) when my IP changes. How can I do this from the terminal?


title: How can I get a regular gcc etc. under HomeBrew under Mac OSX Mountain Lion?

text: I have a Mac with command-line developer tools installed, including Apple's LLVM C compiler, present as /bin/gcc. How can I get a real gcc installed so that e.g. make will see the standard gcc instead of the LLVM compiler?


title: How to play set top box file in PC?

text: The recorded file has .mpg extension. I even tried playing in WMP and VLC and there is another file in USB with .NAV extension. Even tried Miro


title: What does "mounting fs with errors" mean in dmesg and what to do after that?

text: I run dmesg and this is what I see:               EXT4-fs (sda1): warning: mounting fs with errors, running e2fsck is recommended     EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts:       Here is the stuff in context               EXT3-fs (sdd1): using internal journal     EXT3-fs (sdd1): mounted filesystem with ordered data mode     EXT4-fs (sda1): warning: mounting fs with errors, running e2fsck is recommended     EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts:      EXT4-fs (sdb1): warning: maximal mount count reached, running e2fsck is recommended     EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts:      EXT4-fs (sdc1): warning: maximal mount count reached, running e2fsck is recommended     EXT4-fs (sdc1): mounted filesystem with ordered data mode. Opts:      Adding 4194296k swap on /dev/sdd2.  Priority:-1 extents:1 across:4194296k SSD     kjournald starting.  Commit interval 5 seconds     EXT3-fs (loop0): warning: maximal mount count reached, running e2fsck is recommended     EXT3-fs (loop0): using internal journal     EXT3-fs (loop0): mounted filesystem with ordered data mode      what is e2fsck anyway? How to run it?


title: "Unable to initialize SDL" error when trying to play games

text: When I run one of my games I get: > Unable to initialize SDL: No available video device I think that this is due my built-in SIS graphics card, which doesn't have a driver. However, flash games play normally. Here is my X configuration file if it can help (self edited):               Section "Device"         Identifier  "Configured Video Device"         Driver      "vesa"     EndSection          Section "Monitor"         Identifier "Generic Monitor"         Option "DPMS"         HorizSync 27-149         VertRefresh 43-172     EndSection          Section "Screen"         Identifier "Default Screen"         Device "Generic Video Card"         Monitor "Generic Monitor"         DefaultDepth 24             SubSection "Display"             Depth 24             Modes "1280x1024" "1024x768" "800x600" "640x480"             EndSubSection     EndSection      Is there a way to fix this without getting a dedicated graphics card?


title: Patching Process in AIX

text: I am new to the world of AIX and I am pretty unsure on how the patching process goes about. I just joined a new company and they are using AIX as their preferred OS (actually due to having all IBM hardware) So I have just a few patches but NOWHERE on the internet could I find how to download the patches. BTW the machines are not connected to the internet.


title: bulk rename (or correctly display) files with special characters

text: I have a bunch of directories and subdirectories that contain files with special characters, like this file:               robbie@phil:~$ ls test�sktest.txt      test?sktest.txt      Find reveals an escape sequence:               robbie@phil:~$ find test�sktest.txt -ls      424512 4000 -rwxr--r-x   1 robbie   robbie    4091743 Jan 26 00:34 test\323sktest.txt      The only reason I can even type their names on the console is because of tab completion. This also means I can rename them manually (and strip the special character). I've set LC_ALL to UTF-8, which does not seem to help (also not on a new shell):               robbie@phil:~$ echo $LC_ALL     en_US.UTF-8      I'm connecting to the machine using ssh from my mac. It's an Ubuntu install:               robbie@phil:~$ cat /etc/lsb-release      DISTRIB_ID=Ubuntu     DISTRIB_RELEASE=7.10     DISTRIB_CODENAME=gutsy     DISTRIB_DESCRIPTION="Ubuntu 7.10"      Shell is Bash, TERM is set to xterm-color. These files have been there for quite a while, and they have not been created using that install of Ubuntu. So I don't know what the system encoding settings used to be. I've tried things along the lines of:               find . -type f -ls | sed 's/[^a-zA-Z0-9]//g'      But I can't find a solution that does everything I want:   1. Identify all files that have undisplayable characters (the above ignores way too much)   2. For all those files in a directory tree (recursively), execute mv oldname newname   3. Optionally, the ability to transliterate special characters such as ä to a (not required, but would be awesome) OR   1. Correctly display all these files (and no errors in applications when trying to open them) I have bits and pieces, like iterating over all files and moving them, but identifying the files and formatting them correctly for the mv command seems to be the hard part. Any extra information as to why they do not display correctly, or how to "guess" the correct encoding are also welcome. (I've tried convmv but it doesn't seem to do exactly what I want: http://j3e.de/linux/convmv/)


title: Where are the mount points defined in CentOS?

text: There is a mount point at /mnt/mountname and it goes to a large SAN with lots of storage but it's mounted as a read-only filesystem. I want to add a mount point with a different name that's read-write. I've looked in /etc/fstab and /etc/vfstab (which doesn't exist) and there is nothing there that mentions /mnt/mountname. Where else can I look?


title: Audio frequency spectrum of a video at a given time

text: Is there a simple way to get the audio frequency spectrum at a given time of a video? My motivation is the following: I was wondering if it is possible to "measure" the Doppler shift from YouTube videos like this using only my laptop.


title: Matlab's Image acquisition toolbox doesn't recognize my webcam

text: I have to work with the image acquisition toolbox in Matlab and I find it quite disturbing to always change to windows. So I installed Matlab 2010b on my Linux machine (Arch, Kernel 39). Skype & friends work perfectly with my camera (using uvcvideo/video4linux2) but Matlab doesn't. It is a built-in laptop camera and I (my user) am in the video group. Matlab says               >> imaqhwinfo     ans =         InstalledAdaptors: {}             MATLABVersion: '7.11 (R2010b)'               ToolboxName: 'Image Acquisition Toolbox'             ToolboxVersion: '4.0 (R2010b)'      Googeling just told me, that the toolbox should support video4linux2 and that I should not run into problems if the camera can be used by other software. It might be important, that I use Matlab 64 bit while " _lsmod | grep v4l2_ " says:               v4l2_compat_ioctl32     8364  1 videodev      Does this mean that my video4linux2 driver is 32 bit?


title: How to install libesedb? Build error

text: I'm trying to build the libesedb package so I can read edb files. I went to: http://code.google.com/p/libesedb/wiki/Building and found the following:               tar xfv libesedb-alpha-<version>.tar.gz     cd libesedb-<version>     ./configure     make      So I extracted the files into the folder `libesedb-20120102` I then cd to the folder and used `./configure` - it returned the following:               si@siMint ~/Desktop/libesedb-20120102 $ ./configure     checking for a BSD-compatible install... /usr/bin/install -c     checking whether build environment is sane... yes     checking for a thread-safe mkdir -p... /bin/mkdir -p     checking for gawk... gawk     checking whether make sets $(MAKE)... yes     checking build system type... x86_64-unknown-linux-gnu     checking host system type... x86_64-unknown-linux-gnu     checking for style of include used by make... GNU     checking for gcc... gcc     checking whether the C compiler works... no     configure: error: in `/home/si/Desktop/libesedb-20120102':     configure: error: C compiler cannot create executables     See `config.log' for more details.      I ran `make` anyway, and got this:               si@siMint ~/Desktop/libesedb-20120102 $ make     make: *** No targets specified and no makefile found. Stop.      I'm using Linux Mint (16, Cinnamon). Can anyone tell me what's going wrong?


title: Use of O_DIRECT on Linux

text: If this question is too programmer oriented, let me know. I wonder if there are people familiar with the O_DIRECT flag for the open() system call on Linux 2.6? Linus disparages its use, however high performance file writing seems to indicate its use. I would like to know of any real world experience and recommendations. More info: The application that I am using _does_ maintain its own cache, and in so doing attains an average of 5x or more speed up by doing so. When writing to file, the contents of the cache must be written out to the filesystem cache, which seems redundant and a performance concern.


title: Emacs, complete list of color "keys"

text: If you want to customize the colors in Emacs, specifying them in the `.emacs` init file, without installing any extra package, and without using a pre-made theme, something like this seems to work:               (set-background-color "#003c3c")     (set-foreground-color "#ffffff")     (set-face-background 'fringe "#253c3c")     (set-face-background 'cursor "#ffffff")     (set-face-background 'region "#ff0000")     (set-face-foreground 'font-lock-comment-face "#ff0000")     (set-cursor-color "#00ff00")      But for doing this, it would be useful to have a complete list of all the "keys" for these "key-value" pairs. (I don't know if "key" is the right term in Emacs-lingo.. just getting started with Emacs) Is such a complete list available anywhere? Or can I somehow generate one? (I currently use the GNU OSX version of Emacs in its own window, not in a terminal)


title: restore filesystem after fdisk

text: I split a partition in two with `fdisk`, but after rebooting I've got partition in FAT filesystem (was ext4). What's can be wrong? And how to fix it or get data from bad partition? I hope this is possible. List of commands what I did:               resize2fs /dev/sda3 300G     fdisk /dev/sda     //here I remove sda3 partition and create 2 new for sda3 and sda4.     //w and reboot...          //...and I've got this structure:     Disk /dev/sda: 750.2 GB, 750156374016 bytes     255 heads, 63 sectors/track, 91201 cylinders, total 1465149168 sectors     Units = sectors of 1 * 512 = 512 bytes     Sector size (logical/physical): 512 bytes / 512 bytes     I/O size (minimum/optimal): 512 bytes / 512 bytes     Disk identifier: 0x3e74fdb8          Device Boot      Start         End      Blocks   Id  System     /dev/sda1           16065      626534      305235   de  Dell Utility     /dev/sda2          626535     6924014     3148740   82  Linux swap / Solaris     /dev/sda3   *     6924015   636069614   314572800   83  Linux     /dev/sda4       636069615  1465149167   414539776+  83  Linux      `mount` say me what he cannot read superblock so I've use `e2fsck` for start with some alternate superblock and try to use all superblocks from `mke2fs` output. Also I've try `mount -f -t ext4 /dev/sda3 tempdir`. `testdisk` found all needed partition, but only in `[none]` search mode. As I understand, they output can use for fixing size of filesystem or for recovering data, but I don't understand her output.               Disk /dev/sda - 750 GB / 698 GiB - CHS 91202 255 63               Partition                  Start        End    Size in sectors             P ext3                     1   0  1    38 254 57     610464        P FAT32                  431   0  1   561 254 63    2104515 [NO NAME]        P ext4                   431   4 20 39593 132 25  629145600        P ext4                 39593 128  5 91201  80 60  829079552          Write isn't available because the partition table type "None" has been selected.      Can someone tell me how to use this data for manually restore partition filesystem or move data to another partition?


title: Resetting MMC controller without physically removing the card?

text: I'm trying to rescue data from an SDHC card using ddrescue:               while true ; do ddrescue -d /dev/mmcblk0p1 mmc.img mmc.log ; done      The controller, I'm not sure if it's the one on the card or the one in my laptop, seems to return errors for all sectors (which shows up in syslog) after a certain number of bad sectors have been read (which don't show up in syslog), I found that popping the card out and into the slot again resets this and reports good sectors as good again until too many bad sectors have been read, and so on. Currently I'm using this loop, keeping an eye on ddrescue's status output, resetting the card manually. _Is there a way to reset the controller without removing the card, so the rescue process can run unattended?_ Maybe this is related, but in this Dell laptop, for the reader to even notice a card has been inserted it must be done during boot or using `echo 1 > /sys/bus/pci/rescan`, but only once, after that the reader PCI device appears, and everything works as expected:               07:00.0 System peripheral: JMicron Technology Corp. SD/MMC Host Controller (rev 30)             Subsystem: Dell Device 046e             Flags: bus master, fast devsel, latency 0, IRQ 16             Memory at f0600000 (32-bit, non-prefetchable) [size=256]             Capabilities: [a4] Power Management version 3             Capabilities: [80] Express Endpoint, MSI 00             Capabilities: [94] MSI: Enable- Count=1/1 Maskable- 64bit-             Kernel driver in use: sdhci-pci      Relevant syslog:               # pop in card     mmc0: new SDHC card at address b368     mmcblk0: mmc0:b368 NCard 15.0 GiB (ro)     mmcblk0: p1     # ddrescue begins to read, error count increases, until at some point:     mmcblk0: error -110 transferring data, sector 12854624, nr 1, cmd response 0x900, card status 0x0     end_request: I/O error, dev mmcblk0, sector 12854624     mmcblk0: error -110 transferring data, sector 12854625, nr 1, cmd response 0x900, card status 0x0     end_request: I/O error, dev mmcblk0, sector 12854625     mmcblk0: error -110 transferring data, sector 12854626, nr 1, cmd response 0x900, card status 0x0     end_request: I/O error, dev mmcblk0, sector 12854626     mmcblk0: error -110 transferring data, sector 12854627, nr 1, cmd response 0x900, card status 0x0     end_request: I/O error, dev mmcblk0, sector 12854627     mmcblk0: error -110 transferring data, sector 12854628, nr 1, cmd response 0x900, card status 0x0     end_request: I/O error, dev mmcblk0, sector 12854628     # time since last successful read increases, pop out card     mmc0: Card removed during transfer!     mmc0: Resetting controller.     mmcblk0: error -123 sending status command, retrying     mmcblk0: error -123 sending status command, retrying     mmcblk0: error -123 sending status command, aborting     mmc0: card b368 removed     # GOTO 10      I also tried using a USB card reader, instead of generating these errors in syslog, it just disappears and needs to be re-plugged to continue. * * * It seems reloading the `sdhci_pci` module does the trick, but I wonder if there's a less brute-force option to do this:               while sleep 1 ; do         ddrescue -d -T 1 /dev/mmcblk0p1 mmc.img mmc.log          modprobe -r sdhci_pci         modprobe sdhci_pci     done


title: How to specify characters using hexadecimal codes in `grep`?

text: I am using following command to grep character set range for hexadecimal code 0900 (instead of अ) to 097F (instead of व). How I can use hexadecimal code in place of अ and व?               bzcat archive.bz2 | grep -v '<[अ-व]*\s' | tr '[:punct:][:blank:][:digit:]' '\n' | uniq | grep -o '^[अ-व]*$' | sort -f | uniq -c | sort -nr | head -50000 | awk '{print "<w f=\""$1"\">"$2"</w>"}' > hindi.xml      I get the following output...                   <w f="399651">और</w>         <w f="264423">एक</w>         <w f="213707">पर</w>         <w f="74728">कर</w>         <w f="44281">तक</w>         <w f="35125">कई</w>         <w f="26628">द</w>         <w f="23981">इन</w>         <w f="22861">जब</w>          ...      I just want to use hexadecimal code instead of अ and व in the above command. Any suggestion to do it will be greatly appreciated. If using hexadecimal code is not at all possible , can I use unicode instead of hexadecimal code for character set ('अ-व') ? I am using Ubuntu 10.04


title: How to enable (format) a disk in SunOS then add it to a DiskGroup?

text: SERVER # vxdisk list     DEVICE       TYPE            DISK         GROUP        STATUS     c1t0d0s2     auto:none       -            -            online invalid     c1t1d0s2     auto:none       -            -            online invalid     san_vc0_0    auto:sliced     -            -            online     san_vc0_1    auto:sliced     -            -            online     san_vc0_2    auto:sliced     ldisk_64_200p  oraclep_dg1  online     san_vc0_3    auto:sliced     ldisk_64_101p  autosys_dg0  online     san_vc0_4    auto:sliced     ldisk_64_100p  autosys_dg0  online     san_vc0_5    auto            -            -            nolabel     san_vc0_6    auto            -            -            nolabel     san_vc1_0    auto:sliced     -            -            online     san_vc1_1    auto:sliced     -            -            online     san_vc1_2    auto:sliced     ldisk_64_200m  oraclep_dg1  online     san_vc1_3    auto:sliced     ldisk_64_101m  autosys_dg0  online     san_vc1_4    auto:sliced     ldisk_64_100m  autosys_dg0  online     san_vc1_5    auto            -            -            nolabel     san_vc1_6    auto            -            -            nolabel     SERVER #       Other information:               # vxdisk -s list     ...     Disk:   san_vc1_6     type:   auto     flags:  nolabel private autoconfig     error:  Disk is not usable     guid:   -     udid:   AAA%5F2145%5F02006380d018XX00%5F60050768018E03406000000000000475     info:        ...      Why? There are new disks, and I can't add them to a DiskGroup because: "Disk is not usable".               san_vc1_5     san_vc1_6     san_vc0_5     san_vc0_6      How can I enable these new SAN disks + add them to the volume group (vxdiskadm is good for this)   What am I missing? What do I need to do to get the new disks to look like: "auto:sliced"?      Just say if any information is needed... :\ **UPDATE: when I try to format the disks the format says: "No disks found" :\ - what could the problem be?? Are the disks bad??**


title: Behavior of filesystem when mount option has been specified as error=panic

text: **Background** I have a debian system on which I have something like the following in the fstab file.               /dev/sda1 / ext3 defaults,noatime,errors=panic 0 0      The option I wish to focus on is the **errors=panic**. According to the man page, it states the following. > Define the behaviour when an error is encountered. (Either ignore errors and > just mark the file system erroneous and continue, or remount the file system > read‐only, or panic and halt the system.) The default is set in the > filesystem superblock, and can be changed using tune2fs(8). Based on my understanding, an error when mounting would cause a kernel panic, which is fine. What I want to know is what happens when the kernel encounters an error when using the filesystem? Does it cause a kernel panic as specified by the mount option or does it use the option specified in the superblock as shown by tune2fs (or is that option overridden by the mount command) or does it do something else? If it does something else, what does it do and what can I look for for extra reading?


title: Understanding colors in zsh

text: In this thread, yoda suggests the following solution for using colors in `zsh`               #load colors     autoload colors && colors     for COLOR in RED GREEN YELLOW BLUE MAGENTA CYAN BLACK WHITE; do         eval $COLOR='%{$fg_no_bold[${(L)COLOR}]%}'  #wrap colours between %{ %} to avoid weird gaps in autocomplete         eval BOLD_$COLOR='%{$fg_bold[${(L)COLOR}]%}'     done     eval RESET='$reset_color'      Correct me if I am wrong, but if I understand correctly, `autoload colors && colors` allows you to call colors by their name, while the rest of the script just wraps them in `${ $}`. This made me think about the following questions:   1. Is there a way to know what colors are loaded by calling `autoload colors && colors`?    2. How do I know what colors are supported by my terminal?


title: Problem with calling program from the command line

text: Note: this is a cross post with this post on SO. I am trying to build a command line wrapper in Python 3 for an exiting command line tool called 'spooky' and I am having a hard time understanding some strange behavior. If I type `spooky` on the command line, it brings up the man page for spooky. If I enter the path to the spooky tool (`/path/to/spooky`) on the command line it also brings up the man page for spooky. I can run the spooky program successfully if I place spooky in my path and then enter the required arguments like this:               `$ spooky -a 50 -b .97`      However, if I do not put spooky in my path and type the following the command it will not run.               `$ /path/to/spooky -a 50 -b .97`      Why won't this program run when I enter the program's path and then the required arguments? Thanks for the help!


title: How do I cat a command file?

text: I have the output of the `crontab -l` stored in a file (crontab_file) with no extension. But whenever I try to `cat` it, I get errors saying command not found for multiple line of the file. Here is the code I have so far:               file/commands/crontab_file > $PWD/tmp     cat $PWD/tmp      I keep getting an error and I don't know why (maybe since I am a beginner). Any suggestions?


title: ext4 to btrfs conversion: Can I pause, reboot the system and then resume the conversion?

text: I want to convert a rather big ext4 volume into btrfs. How long will the process will take?


title: How to extract files from uImage?

text: Buildroot is generating Images for an embedded device where they should run on. This is working very well. In those Images the rootfs is included. Due to some research I'd like to look into that generated file (e.g: different compression modes set by Buildroot were applied and now shall be checked if they were correctly done) but I can't find something usefull in the Net. As far as I know the difference between a uImage and zImage is just a small header, so u-boot is able to read that binary file. But I can open neither uImage nor the zImage. Can anyone give me a hint of how to decompress those (u/z)Images on the host?


title: Viking GPS editor/viewer: how to scroll the map while entering points in a track?

text: I just discovered the (great) Viking application for editing and viewing GPS tracks. I am struggling to find a way to scroll the map while I am editing?adding points to a track or a route, like in the following case: ![enter image description here](http://i.stack.imgur.com/E7W1A.png) I know I can click on the "four arrow" symbol and then move the map, but this will exit the track editing mode --- I have to select "extend track" to continue each time. I am sure there should be a better method, but I am unable to find it. Is there a way to scroll the map while in track editing mode?


title: env command shows 3 times same path

text: When i run `env` it shows 3 times `/usr/bin` under PATH . Same for every path under `PATH` title.   For example - my scala bin directory shows 3 times .      However, in my .bash_profile, it is written just one time . Also its not in .bashrc also. I need to make this 3 occurrences to 1, as even though I remove some path under PATH in .bash_profile, it still shows 2 times , which means that path is still set.      `echo $PATH `shows the same thing.   And , if it matters I am using macosx.


title: On why touch, mv, etc., won't create subdirectories "as needed"

text: There are many Unix commands that will fail unless some subdirectory already exists, even though it would be a trivial matter for such commands to go ahead and create the missing subdirectory before proceeding. For example, for `touch`:               % touch /tmp/foo/bar/baz/frobozz     touch: cannot touch `/tmp/foo/bar/baz': No such file or directory     % mkdir -p /tmp/foo/bar/baz     % touch /tmp/foo/bar/baz/frobozz # succeeds      Similarly, for `mv`:               % mv --target-directory=/tmp/foo/frotz/quux /tmp/foo/bar/frobozz     % mv: failed to access `/tmp/foo/frotz/quux': No such file or directory     % mkdir -p /tmp/foo/frotz/quux     % mv --target-directory=/tmp/foo/frotz/quux /tmp/foo/bar/frobozz # succeeds      One notable exception to this behavior is `mkdir` itself, whose `-p` flag tells it to "create subdirectories as needed". I am a bit puzzled by the fact that `touch`, `mv`, et al. won't do the "obvious thing", either by default, or upon request via some flag (such as `mkdir`'s `-p`). I figure there must be a very good reason for this, but it's not obvious to me. Insights welcome. (The motivation for asking this is that I'd like to implement a utility that is pretty much like the (nonstandard) `mmv` utility, except that, contrary to the real `mmv`, it _would_ "create subdirectories as needed", and I'm wondering if this new feature would be A Really Bad Idea. For example, with the utility I'm thinking of--let me call it `mmmv`-- one would be able to simultaneously move and rename the files               1caf73ee55b4e11d6e3b12ccbf8c477c2839bfae     1f37fd8ce865f98579d10d8045ac1e88c6717215     73f2af84ba8ed27fa332d52745274377aa67cda5     a257a7c7cac26c391e8636193ff47b45c5e587ec      to               1c/af73ee55b4e11d6e3b12ccbf8c477c2839bfae     1f/37fd8ce865f98579d10d8045ac1e88c6717215     a2/57a7c7cac26c391e8636193ff47b45c5e587ec     73/f2af84ba8ed27fa332d52745274377aa67cda5      with a single command, like this:               % mmmv '??*' '#1#2/#3'      For this to be possible `mmmv` needs to be able to create the two-letter-named subdirectories as needed.)


title: Why sudo ./bin/mysqld_safe & on Mac OS X 10.6.8 doesn't ask for password?

text: I get the following permissions from terminal:               $ cd /usr/local/mysql       $ ls -l       drwxr-xr-x  41 root    wheel  1394 29 Apr 00:55 bin       drwxr-xr-x   4 root    wheel   136 29 Apr 00:55 docs       drwxr-xr-x   3 root    wheel   102 29 Apr 00:55 include        drwxr-xr-x   3 root    wheel   102 29 Apr 00:55 lib       drwxr-xr-x   4 root    wheel   136 29 Apr 00:55 libexec       drwxr-xr-x  15 root    wheel   510 29 Apr 00:55 mysql-test        drwxr-xr-x   5 root    wheel   170 29 Apr 00:55 share       drwxr-xr-x  29 root    wheel   986 29 Apr 00:55 sql-bench       drwxrwxr-x   3 _mysql  wheel   102  5 Mag 10:56 tmp       drwxrwxr-x  16 _mysql  wheel   544  5 Mag 10:56 var        (mysqld_safe itself has 755). tmp is where mysql.sock resides, var contains the databases. MySQL starts normally with sudo, as specified in the question, but without asking for root password, even after a boot. If mysqld_safe is issued without sudo it obviously fails and complains (permission denied on file in ./var). sudoers file contains just the line below regarding permissions:               root    ALL=(ALL) ALL


title: Can removed Debian packages have leftover files?

text: I noticed a weird thing in my /etc/init.d files and tried to look a bit what was going on. Here's my problem:                # apt-file search /etc/init.d/minissdpd      minissdpd: /etc/init.d/minissdpd           # dpkg-query -L minissdpd     /etc     /etc/default     /etc/default/minissdpd     /etc/init.d     /etc/init.d/minissdpd           # apt-get remove minissdpd     Reading package lists... Done     Building dependency tree            Reading state information... Done     Package 'minissdpd' is not installed, so not removed     0 upgraded, 0 newly installed, 0 to remove and 177 not upgraded.      How comes there are files from minissdpd yet it says minissdpd isn't installed? Can I safely delete those?


title: Location of application files?

text: Does Linux/Unix have a unified location for Application files, like "~/Library/Application Support" on Mac OS X? I'm making a Python script that will need to store permanent but changing data, and I want it to work universally.


title: GNU screen color and pine

text: I use GNU screen to run pine mail reader. I use external aspell to do spellchecking for the e-mails I sent. The problem is that when aspell finishes, pine restores the old content of the terminal, but the color is all wrong. The font becomes white instead of black, which looks very bad on the the gray background. After typing something for a while, pine redraws parts of the screen, and that looks ok, but initially it looks very hard to read. The problem does not exist when pine is run directly, not from within screen. I do not know how to begin the troubleshooting. Any ideas?               Pine version: Alpine 2.00 (LRH 1167 2008-08-23)      GNU screen version: Screen version 4.00.03 (FAU) 23-Oct-06      **Update 11 Dec 2011:** The problem also occurs in some cases when resuming composition with Ctrl+O (no aspell involed). The following do not help:   * Ctrl+L in pine to refesh screen,    * adding "altscreen on" in `~/.screenrc`   * adding "bce on" or "bce off" in `~/.screenrc` (I tried both, as I am not sure what the default is)    * Starting screen with `TERM=xterm-256color screen`


title: Remove first instance of lines with duplicate field value

text: I have sha1 summed all the image files on my storage server and put the results in a text file in the form of: sha1sum filename I've sorted the file and removed all all unique sha1sum entries. So what I am left with is a list of duplicate files. Some have two entries, some three, some even more. What I want to do is to remove _only the first_ entry of each duplicate sha1sum so I can use the resulting output to delete the duplicate files (and keep only one instance of each) I don't really care which version gets kept as I will be moving all the files into some form of directory hierarchy later


title: Ubuntu: wire network is not stable and must restart network-manager periodcally

text: I don't know why my wire network now is not stable. After a short time of using, maybe 30 minutes, 15 minutes or maybe just 2 minutes, my network is down. When my network is down, I must run this command two times:               service network-manager restart      First time, it just disconnect network. and at second time, it restarts the network and runs smoothly again. I don't know why and how to fix this. I'm using Ubuntu 13.04. Before that, I used Fedora 18, and still meet this problem.


title: Choppy sound with flashpayer

text: After a number of updates, including upgrading to flashplayer 11 and kernel 3.8.2 sound from flashplayer and skype has become choppy. **Setup** In my setup I have .ascoundrc set up to use pulseaudio (copied from somewhere, because I have no clue about the syntax of .asoundrc)               pcm.pulse {         type pulse     }     ctl.pulse {         type pulse     }     pcm.!default {         type pulse     }     ctl.!default {         type pulse     }      Pulseaudio is setup to use jack as source and sink. Jack uses a firewire mixing console as soundcard. And in case it matters, I have an nvidia graphics card (GeForce 8800 GT) with the proprietary drivers from nvidia (NVIDIA-Linux-x86-310.40) . **Symptoms** Sound from vlc or celementine works flawlessly. I believe these talk to pulseaudio directly. Using mplayer I can choose between `-ao` `alsa` `pulse` and `jack` and all work okay.So I have no reason to believe there is anything wrong on the tail end of the chain, i.e. pulse->jack->firewire. But also aplay works fine, which I believe, must go through the alsa layer to access pulse. Skype and especially flashplayer produce choppy sound, as if the samplerate were not right and the system has to jump a number of samples back or forth every half second or so. Flash shows this behavior not just in Firefox, but also in Chrome. Skype sometimes works okay, i.e. when I kill and restart it I can get it to work. **Analyses so far** I have compared the output of `pactl list` when playing from aplay, firefox or skype and could not see any clues. My sample-rate seems to be 44100 and Skype comes in with 44800 so pactl shows that a `speex-float-3` resampling is happening. But I can aplay wave files with 44100 and 48000, so my original hunch, that resampling is causing the problems is probably not right. I also compared the `ldd` output of aplay and skype and skype uses the same shared libraries as aplay, plus of course some more. I have tried to use the alsa jack plugin, such that alsa talks directly to jack, bypassing pulse, but then flash playback stops producing sound after a few seconds. CPU usage is high when playing flash               16494 23.6 478m     1 martin    1000 1 S  20   0   58 firefox     14797  4.7  95m  4097 root         0 1 S  20   0   11 xorg     15979  5.1 103m 15806 martin    1000 1 S  20   0    7 jackd     25561  8.5 172m     1 martin    1000 0 S   9 -11    5 pulseaudio     25534  4.1  82m 17830 martin    1000 0 S  20   0    2 skype      `dmesg` occasionally shows               pulseaudio[15996]: segfault at 0 ip b256416a sp bfe34d40 error 4 in module-jack-sink.so[b2562000+4000]      This is certainly "not good", but pulseaudio gets restarted okay when needed There is nothing in /var/log/messages or .xsession-error or on stdout/stderr of firefox or chrome. Any help would be much appreciated. I would also be happy about pointers, where to look next or what to google. The strange thing is, that not many seem to have this problem.


title: OpenBSD 5.2 and Intel GMA X4500: How to get the X Window System to work

text: I've just installed OpenBSD 5.2 on my desktop computer and I can't get the X Window System to work. My graphics card is Intel GMA X4500. When I run `startx`, my system freezes and no keyboard interaction is possible. So I perform a hard reset. Moreover, `X -configure` gives me segmentation faults and the X configuration is aborted. Has anyone managed to get Intel GMA X4500 and X working perfectly?


title: Reorder items in an XFCE4 menu

text: In the Application menu, the "Lock Screen" item is misplaced, does anyone know how to place it just above "Log Out"? ![Lock Screen](http://i.stack.imgur.com/Z6d9r.png) Shows "Lock Screen" somewhere in the middle but should appear near the bottom, above "Log Out".


title: Cannot connect to ethernet on a cable modem

text: I have an **Arris** cable modem, and my laptop has a **JMC250 PCI Express Gigabit Ethernet Controller**. I'm unable to connect to its wired network either with NetworkManager, Wicd, or the command-line on Debian Stable. I have tried also running a Porteus (Slackware based) LiveCD, but the result was the same. I have tried also many times unloading the `jme` module and reloading it, with no options, and also with the options `force_pseudohp=1`, `no_pseudohp=1`, and `no_extplug=1`, but to no avail. I have also tried turning off the rfkill switch, because I can connect to the Wifi without any problems using NetworkManager. Here is the log from when trying to connect with the NetworkManager:               Feb  5 15:38:50 localhost NetworkManager[2225]: <info> enable requested (sleeping: no  enabled: no)     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> waking up and re-enabling...     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (wlan0): now managed     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (wlan0): device state change: unmanaged -> unavailable (reason 'managed') [10 20 2]     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (wlan0): bringing up device.     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (wlan0): deactivating device (reason 'managed') [2]     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (eth0): now managed     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (eth0): device state change: unmanaged -> unavailable (reason 'managed') [10 20 2]     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (eth0): preparing device.     Feb  5 15:38:50 localhost NetworkManager[2225]: <info> (eth0): deactivating device (reason 'managed') [2]      The log from Wicd (which uses standard command-line tools):               2014/02/05 15:35:50 :: Executing /etc/network/if-down.d/upstart with params      2014/02/05 15:35:50 :: /etc/network/if-down.d/upstart returned 0     2014/02/05 15:35:50 :: Executing /etc/network/if-down.d/wpasupplicant with params      2014/02/05 15:35:50 :: /etc/network/if-down.d/wpasupplicant returned 0     2014/02/05 15:35:50 :: attempting to set hostname with dhclient     2014/02/05 15:35:50 :: using dhcpcd or another supported client may work better     2014/02/05 15:35:50 :: /sbin/dhclient -v -r wlan0     2014/02/05 15:35:50 :: ifconfig wlan0 0.0.0.0      2014/02/05 15:35:50 :: /sbin/ip route flush dev wlan0     2014/02/05 15:35:50 :: ifconfig wlan0 down     2014/02/05 15:35:50 :: ifconfig wlan0 up     2014/02/05 15:35:50 :: Executing /etc/network/if-post-down.d/wireless-tools with params      2014/02/05 15:35:50 :: /etc/network/if-post-down.d/wireless-tools returned 0     2014/02/05 15:35:50 :: Executing /etc/network/if-post-down.d/wpasupplicant with params      2014/02/05 15:35:50 :: /etc/network/if-post-down.d/wpasupplicant returned 0     2014/02/05 15:35:50 :: wpa_cli -i wlan0 terminate     2014/02/05 15:35:50 :: Executing /etc/network/if-down.d/upstart with params      2014/02/05 15:35:50 :: /etc/network/if-down.d/upstart returned 0     2014/02/05 15:35:50 :: Executing /etc/network/if-down.d/wpasupplicant with params      2014/02/05 15:35:50 :: /etc/network/if-down.d/wpasupplicant returned 0     2014/02/05 15:35:50 :: attempting to set hostname with dhclient     2014/02/05 15:35:50 :: using dhcpcd or another supported client may work better     2014/02/05 15:35:50 :: /sbin/dhclient -v -r eth0     2014/02/05 15:35:50 :: ifconfig eth0 0.0.0.0      2014/02/05 15:35:50 :: /sbin/ip route flush dev eth0     2014/02/05 15:35:50 :: ifconfig eth0 down     2014/02/05 15:35:50 :: ifconfig eth0 up     2014/02/05 15:35:50 :: Executing /etc/network/if-post-down.d/wireless-tools with params      2014/02/05 15:35:50 :: /etc/network/if-post-down.d/wireless-tools returned 0     2014/02/05 15:35:50 :: Executing /etc/network/if-post-down.d/wpasupplicant with params      2014/02/05 15:35:50 :: /etc/network/if-post-down.d/wpasupplicant returned 0     2014/02/05 15:35:50 :: wpa_cli -i eth0 terminate     2014/02/05 15:35:50 :: found lastused in configuration True     2014/02/05 15:35:50 :: Executing /etc/network/if-pre-up.d/ethtool with params      2014/02/05 15:35:50 :: /etc/network/if-pre-up.d/ethtool returned 0     2014/02/05 15:35:50 :: Executing /etc/network/if-pre-up.d/wireless-tools with params      2014/02/05 15:35:50 :: /etc/network/if-pre-up.d/wireless-tools returned 0     2014/02/05 15:35:50 :: Executing /etc/network/if-pre-up.d/wpasupplicant with params      2014/02/05 15:35:50 :: /etc/network/if-pre-up.d/wpasupplicant returned 0     2014/02/05 15:35:50 :: Putting interface down     2014/02/05 15:35:50 :: ifconfig eth0 down     2014/02/05 15:35:50 :: Releasing DHCP leases...     2014/02/05 15:35:50 :: attempting to set hostname with dhclient     2014/02/05 15:35:50 :: using dhcpcd or another supported client may work better     2014/02/05 15:35:50 :: /sbin/dhclient -v -r eth0     2014/02/05 15:35:50 :: Setting false IP...     2014/02/05 15:35:50 :: ifconfig eth0 0.0.0.0      2014/02/05 15:35:50 :: Stopping wpa_supplicant     2014/02/05 15:35:50 :: wpa_cli -i eth0 terminate     2014/02/05 15:35:50 :: Flushing the routing table...     2014/02/05 15:35:50 :: /sbin/ip route flush dev eth0     2014/02/05 15:35:50 :: Putting interface up...     2014/02/05 15:35:50 :: ifconfig eth0 up     2014/02/05 15:35:52 :: Running DHCP with hostname localhost     2014/02/05 15:35:52 :: attempting to set hostname with dhclient     2014/02/05 15:35:52 :: using dhcpcd or another supported client may work better     2014/02/05 15:35:52 :: /sbin/dhclient -v eth0     2014/02/05 15:35:52 :: Internet Systems Consortium DHCP Client 4.2.2     2014/02/05 15:35:52 :: Copyright 2004-2011 Internet Systems Consortium.     2014/02/05 15:35:52 :: All rights reserved.     2014/02/05 15:35:52 :: For info, please visit https://www.isc.org/software/dhcp/     2014/02/05 15:35:52 ::      2014/02/05 15:35:52 :: Listening on LPF/eth0/80:ee:73:1f:6d:47     2014/02/05 15:35:52 :: Sending on   LPF/eth0/80:ee:73:1f:6d:47     2014/02/05 15:35:52 :: Sending on   Socket/fallback     2014/02/05 15:35:52 :: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8     2014/02/05 15:36:00 :: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 14     2014/02/05 15:36:14 :: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 15     2014/02/05 15:36:29 :: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 17     2014/02/05 15:36:46 :: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 7     2014/02/05 15:36:53 :: No DHCPOFFERS received.     2014/02/05 15:36:53 :: No working leases in persistent database - sleeping.     2014/02/05 15:36:53 :: DHCP connection failed     2014/02/05 15:36:53 :: exiting connection thread     2014/02/05 15:36:53 :: Sending connection attempt result dhcp_failed     2014/02/05 15:36:53 :: ifconfig eth0     2014/02/05 15:36:53 :: ifconfig wlan0     2014/02/05 15:36:53 :: Forced disconnect on     2014/02/05 15:36:53 :: iwconfig wlan0     2014/02/05 15:36:53 :: Executing /etc/network/if-down.d/upstart with params      2014/02/05 15:36:53 :: /etc/network/if-down.d/upstart returned 0     2014/02/05 15:36:53 :: Executing /etc/network/if-down.d/wpasupplicant with params      2014/02/05 15:36:53 :: /etc/network/if-down.d/wpasupplicant returned 0     2014/02/05 15:36:53 :: attempting to set hostname with dhclient     2014/02/05 15:36:53 :: using dhcpcd or another supported client may work better     2014/02/05 15:36:53 :: /sbin/dhclient -v -r wlan0     2014/02/05 15:36:53 :: ifconfig wlan0 0.0.0.0      2014/02/05 15:36:53 :: /sbin/ip route flush dev wlan0     2014/02/05 15:36:53 :: ifconfig wlan0 down     2014/02/05 15:36:53 :: ifconfig wlan0 up     2014/02/05 15:36:53 :: Executing /etc/network/if-post-down.d/wireless-tools with params      2014/02/05 15:36:53 :: /etc/network/if-post-down.d/wireless-tools returned 0     2014/02/05 15:36:53 :: Executing /etc/network/if-post-down.d/wpasupplicant with params      2014/02/05 15:36:53 :: /etc/network/if-post-down.d/wpasupplicant returned 0     2014/02/05 15:36:53 :: wpa_cli -i wlan0 terminate     2014/02/05 15:36:53 :: Executing /etc/network/if-down.d/upstart with params      2014/02/05 15:36:53 :: /etc/network/if-down.d/upstart returned 0     2014/02/05 15:36:53 :: Executing /etc/network/if-down.d/wpasupplicant with params      2014/02/05 15:36:53 :: /etc/network/if-down.d/wpasupplicant returned 0     2014/02/05 15:36:53 :: attempting to set hostname with dhclient     2014/02/05 15:36:53 :: using dhcpcd or another supported client may work better     2014/02/05 15:36:53 :: /sbin/dhclient -v -r eth0     2014/02/05 15:36:53 :: ifconfig eth0 0.0.0.0      2014/02/05 15:36:53 :: /sbin/ip route flush dev eth0     2014/02/05 15:36:53 :: ifconfig eth0 down     2014/02/05 15:36:53 :: ifconfig eth0 up     2014/02/05 15:36:53 :: Executing /etc/network/if-post-down.d/wireless-tools with params      2014/02/05 15:36:53 :: /etc/network/if-post-down.d/wireless-tools returned 0     2014/02/05 15:36:53 :: Executing /etc/network/if-post-down.d/wpasupplicant with params      2014/02/05 15:36:53 :: /etc/network/if-post-down.d/wpasupplicant returned 0     2014/02/05 15:36:53 :: wpa_cli -i eth0 terminate      Some other info:               $ sudo ethtool eth0     Settings for eth0:         Supported ports: [ TP MII ]         Supported link modes:   10baseT/Half 10baseT/Full                                  100baseT/Half 100baseT/Full                                  1000baseT/Half 1000baseT/Full          Supported pause frame use: No         Supports auto-negotiation: Yes         Advertised link modes:  10baseT/Half 10baseT/Full                                  100baseT/Half 100baseT/Full                                  1000baseT/Half 1000baseT/Full          Advertised pause frame use: Symmetric Receive-only         Advertised auto-negotiation: Yes         Speed: 10Mb/s         Duplex: Half         Port: MII         PHYAD: 1         Transceiver: internal         Auto-negotiation: on         Supports Wake-on: pg         Wake-on: g         Current message level: 0x000020c6 (8390)                        probe link rx_err tx_err hw         Link detected: no          $ sudo nm-tool           NetworkManager Tool          State: disconnected          - Device: eth0 -----------------------------------------------------------------       Type:              Wired       Driver:            jme       State:             unavailable       Default:           no       HW Address:        80:EE:73:1F:6D:47            Capabilities:         Carrier Detect:  yes            Wired Properties         Carrier:         off


title: Configuring Apache to Require a Client Certificate

text: I want to implement mutual authentication (two - way ) with apache web server. **References** :   1.Failed to sign CSR with the CA root key   2.Firefox error message when adding client certificate signed by CA after many steps :   1. Configuring Apache 2.0 SSL to accept https by editing ssl.conf .   2. Creating a Certificate Authority using OpenSSL & importing it to the web browser [link]   3. Creating a Web Server Certificate & sign it by CA & put it as apache certificate.[link]   4. Creating a Client Certificate & sign it by CA & export it as PKCS#12 format [link]& import it to web browser  I now have an access with https to the server but for all users .   I want just the authorized users who I gave them a signed certificate by CA to access to web pages on my server . I needed to edit ssl.conf in `/etc/httpd/conf.d/ssl.conf` following this tutorial , I did this to ssl.conf :               SSLVerifyClient require     SSLVerifyDepth 2      **Update#1 :** and of course I had set the certificate to the signed one by CA :               #   Server Certificate:     #SSLCertificateFile /etc/pki/tls/certs/localhost.crt     SSLCertificateFile /var/www/sslConf/server.crt     #   Server Private Key:     #SSLCertificateKeyFile /etc/pki/tls/private/localhost.key     SSLCertificateKeyFile /var/www/sslConf/server.key      and as a result I got this message and after pressing ok this message (in firefox). what's the mistake I had committed ?


title: Can't open the initial console on ARM S3C2440 running utuLinux

text: I try to mount an NFS filesystem to the target board ARM s3C2440. I've started the NFS service and the portmap service. The server operating system is Ubuntu 10.04. I use minicom to communicate with the target board. In the terminal on the server, I typed the command: `showmount -e`               Export list for android-desktop:     /utuLinux2.6.24/s3c2440_recover *      So the configuration of NFS service is right. The directory `/utuLinux2.6.24/s3c2440_recover` on Ubuntu is the directory which I want to mount to the target board s3c2440. The operating system is on the board is utuLinux. I powered on the ARM board, and at the utu-bootloader prompt, I set the `bootargs` environment variable before booting: `$setenv bootargs 'console=ttySAC0 root=/dev/nfs nfsroot=192.168.2.107:/utuLinux2.6.24/s3c2440_recover ip=192.168.2.213:192.168.2.1:192.168.2.1:255.255.255.0:www.yctek.com:eth0:off`   `$boot` But I got an error when booting:               utu-bootloader=>>>setenv bootargs 'console=ttySAC0 root=/dev/nfs nfsroot=192.168.2.107:/utuLinux2.6.24/s3c2440_recover ip=192.168.2.213:192.168.2.1:192.168.'     utu-bootloader=>>>boot          NAND read: device 0 offset 0x60000, size 0x200000          Reading data from 0x25fe00 -- 100% complete.      2097152 bytes read: OK     ## Booting image at 32000000 ...        Image Name:   Linux-2.6.24.4        Created:      2008-12-07  16:50:12 UTC        Image Type:   ARM Linux Kernel Image (uncompressed)        Data Size:    1959328 Bytes =  1.9 MB        Load Address: 30008000        Entry Point:  30008000        Verifying Checksum ... OK     OK          Starting kernel ...          Uncompressing Linux..........................................................................................................................................     Linux version 2.6.24.4 (lili@lili-desktop) (gcc version 3.4.1) #121 Mon Dec 8 00:50:06 CST 2008     CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177     Machine: UTU2440     Memory policy: ECC disabled, Data cache writeback     CPU S3C2440A (id 0x32440001)     S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz     S3C24XX Clocks, (c) 2004 Simtec Electronics     CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on     CPU0: D VIVT write-back cache     CPU0: I cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets     CPU0: D cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets     Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256     Kernel command line: console=ttySAC0 root=/dev/nfs nfsroot=192.168.2.107:/utuLinux2.6.24/s3c2440_recover ip=192.168.2.213:192.168.2.1:192.168.2.1:255.255.25f     irq: clearing pending ext status 00000300     irq: clearing subpending status 00000003     irq: clearing subpending status 00000002     PID hash table entries: 256 (order: 8, 1024 bytes)     timer tcon=00500000, tcnt a4ca, tcfg 00000200,00000000, usec 00001e57     Console: colour dummy device 80x30     console [ttySAC0] enabled     Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)     Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)     Memory: 64MB = 64MB total     Memory: 60160KB available (3556K code, 727K data, 472K init)     SLUB: Genslabs=11, HWalign=32, Order=0-1, MinObjects=4, CPUs=1, Nodes=1     Mount-cache hash table entries: 512     CPU: Testing write buffer coherency: ok     net_namespace: 64 bytes     NET: Registered protocol family 16     S3C2440: Initialising architecture     S3C2440: IRQ Support     S3C2440: Clock Support, DVS off     S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics     DMA channel 0 at c4800000, irq 33     DMA channel 1 at c4800040, irq 34     DMA channel 2 at c4800080, irq 35     DMA channel 3 at c48000c0, irq 36     SCSI subsystem initialized     usbcore: registered new interface driver usbfs     usbcore: registered new interface driver hub     usbcore: registered new device driver usb     NET: Registered protocol family 2     IP route cache hash table entries: 1024 (order: 0, 4096 bytes)     TCP established hash table entries: 2048 (order: 2, 16384 bytes)     TCP bind hash table entries: 2048 (order: 1, 8192 bytes)     TCP: Hash tables configured (established 2048 bind 2048)     TCP reno registered     NetWinder Floating Point Emulator V0.97 (double precision)     NTFS driver 2.1.29 [Flags: R/W].     fuse init (API version 7.9)     yaffs Dec  8 2008 00:45:24 Installing.      io scheduler noop registered     io scheduler cfq registered (default)     Console: switching to colour frame buffer device 100x30     fb0: s3c2410fb frame buffer device     GPIO L3 bus interface for S3C2440, installed     utu2440 LED Driver v1.00     s3c2440-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2440     s3c2440-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2440     s3c2440-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2440     loop: module loaded     nbd: registered device at major 43     dm9000 Ethernet Driver     eth0: dm9000 at c4802300,c4804304 IRQ 53 MAC: 00:12:34:56:80:49     Linux video capture interface: v2.00     em28xx v4l2 driver version 0.0.1 loaded     usbcore: registered new interface driver em28xx     usbcore: registered new interface driver gspca     drivers/media/video/gspca/gspca_core.c: gspca driver 00.60.00 registered     et61x251: V4L2 driver for ET61X[12]51 PC Camera Controllers v1:1.09     usbcore: registered new interface driver et61x251     zc0301: V4L2 driver for ZC0301[P] Image Processor and Control Chip v1:1.10     usbcore: registered new interface driver zc0301     videodev: "vivi" has no release callback. Please fix your driver for proper sysfs support, see http://lwn.net/Articles/36850/     Video Technology Magazine Virtual Video Capture Board (Load status: 0)     Driver 'sd' needs updating - please use bus_type methods     S3C24XX NAND Driver, (c) 2004 Simtec Electronics     s3c2440-nand s3c2440-nand: Tacls=1, 9ns Twrph0=4 39ns, Twrph1=1 9ns     NAND device: Manufacturer ID: 0xec, Chip ID: 0x76 (Samsung NAND 64MiB 3,3V 8-bit)     Scanning device for bad blocks     Bad eraseblock 972 at 0x00f30000     Bad eraseblock 3615 at 0x0387c000     Creating 3 MTD partitions on "NAND 64MiB 3,3V 8-bit":     0x00000000-0x00060000 : "bootloader"     0x00060000-0x00260000 : "kernel"     0x00260000-0x03ffc000 : "root"     s3c2410-ohci s3c2410-ohci: S3C24XX OHCI     s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1     s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000     usb usb1: configuration #1 chosen from 1 choice     hub 1-0:1.0: USB hub found     hub 1-0:1.0: 2 ports detected     Initializing USB Mass Storage driver...     usb 1-1: new full speed USB device using s3c2410-ohci and address 2     usb 1-1: configuration #1 chosen from 1 choice     hub 1-1:1.0: USB hub found     hub 1-1:1.0: 4 ports detected     usbcore: registered new interface driver usb-storage     USB Mass Storage support registered.     usbcore: registered new interface driver libusual     mice: PS/2 mouse device common for all mice     Initial utulinux 2440 Buttons driver!     Todo: mknod c /dev/utu2440-buttons 252 0     s3c2440 TouchScreen successfully loaded     input: s3c2440 TouchScreen as /devices/virtual/input/input0     S3C24XX RTC, (c) 2004,2006 Simtec Electronics     s3c2410-rtc s3c2410-rtc: rtc disabled, re-enabling     s3c2410-rtc s3c2410-rtc: rtc core: registered s3c as rtc0     i2c /dev entries driver     s3c2440-i2c s3c2440-i2c: slave address 0x10     s3c2440-i2c s3c2440-i2c: bus frequency set to 98 KHz     s3c2440-i2c s3c2440-i2c: i2c-0: S3C I2C adapter     S3C2410 Watchdog Timer, (c) 2004 Simtec Electronics     s3c2410-wdt s3c2410-wdt: watchdog inactive, reset disabled, irq enabled     mapped channel 2 to 0     usbcore: registered new interface driver usbkbd     drivers/hid/usbhid/usbkbd.c: :USB HID Boot Protocol keyboard driver     usbcore: registered new interface driver usbmouse     drivers/hid/usbhid/usbmouse.c: v1.6:USB HID Boot Protocol mouse driver     We do iis iomap from here.      mapped channel 10 to 2     mapped channel 9 to 1     Now we have successfully init dma resourse.      UDA1341 audio driver for utu2440 has been initialized     TCP cubic registered     NET: Registered protocol family 1     NET: Registered protocol family 17     RPC: Registered udp transport module.     RPC: Registered tcp transport module.     s3c2410-rtc s3c2410-rtc: hctosys: invalid date/time     eth0: link up, 10Mbps, half-duplex, lpa 0x0021     IP-Config: Complete:           device=eth0, addr=192.168.2.213, mask=255.255.255.0, gw=192.168.2.1,          host=www, domain=, nis-domain=yctek.com,          bootserver=192.168.2.1, rootserver=192.168.2.107, rootpath=     Looking up port of RPC 100003/2 on 192.168.2.107     Looking up port of RPC 100005/1 on 192.168.2.107     VFS: Mounted root (nfs filesystem).     Freeing init memory: 472K     Warning: unable to open an initial console.              _                     _   _                              _   _  | |_   _   _          | | (_)  _ __    _   _  __  __     | | | | | __| | | | |  _____  | | | | | '_ \  | | | | \ \/ /     | |_| | | |_  | |_| | |_____| | | | | | | | | | |_| |  >  <       \__,_|  \__|  \__,_|         |_| |_| |_| |_|  \__,_| /_/\_\    http://www.utu.com.cn/utuLinux      If it had booted successfully, I could have typed the command `mount /dev/mtdblock2 /mnt` and then in the directory `/mnt` I could have seen the root directry of the ARM board. But now I can't control the console. How can I solve this problem?


title: How to install a single Jessie package on Wheezy?

text: I want to install a single package (and its dependencies, but only to the extent those are not satisfiable in Wheezy) from Debian Jessie onto my Wheezy system, without upgrading "everything and the kitchen sink" to the Jessie versions. Specifically, I'd like to install kpcli, which is available packaged in Jessie but not in Wheezy. Everything I've found indicates that I should add the Jessie repositories to my sources list, set pinning to keep everything at wheezy and only take the single package from jessie, and it'll pretty much just fall into place. However, it isn't falling into place for me. If I create /etc/apt.d/sources.list.d/jessie.list with the following content:               deb ftp://ftp.debian.org/debian/ jessie main     deb-src ftp://ftp.debian.org/debian/ jessie main      and then create /etc/apt/preferences.d/jessie with:               Package: *     Pin: release a=wheezy     Pin-Priority: 1001          Package: kpcli     Pin: release a=jessie     Pin-Priority: 450      and run `apt-get -u update` followed by `apt-get -u install kpcli/jessie`, then I expect apt-get to pull in kpcli and _maybe_ a small handful of other packages from Jessie, and leave the remainder of my installed system untouched. (My system is a fully up to date installation of Wheezy.) Alternatively, if I got the pin priority too low, I'd expect it to do nothing. Rather, on my system, _apt-get wants to upgrade several hundred packages._ What, **exactly,** is needed to install just this one single package of a Jessie version while leaving the remainder of my Wheezy system untouched? Note that in this particular case, the software is actually written in Perl so there's no compilation to binary or anything like that involved; however, there is a handful of Perl module dependencies. Hence, one possible alternative would be to install the .deb (downloaded manually) using something that only (1) allows specifying a single, local .deb archive that is to be installed, like `dpkg -i`, and (2) handles dependencies in an intelligent way, which plain `dpkg -i` doesn't. However, for all the searching I've done on several occasions and failed to come up with a simple-to-follow guide for how to do this, a generic solution (one that works for binary, compiled packages as well) would be great.


title: Foreign characters won't display in SSH

text: I'm having some problems with using `ssh` and a remote server (which I do not have admin access to) - Specifically, there are a couple of folders on there with Korean and Cyrillic text. When I display the parent folder contents with `ls`, the characters are escaped as "?". Perhaps of note is that the Korean characters seem to escape far more ?s than the number of characters that _should_ be there. I know that the terminal program I'm using can display the characters, as using `sftp` displays them perfectly. The problem occurs across all terminals I've tried. **Summary of machines** Local machine:   * Linux 2.6.32-5-686, i686   * Debian GNU/Linux 6.0.2 (squeeze)   * Have admin access Remote server:   * Linux 2.6.32-bpo.5-amd64, x86_64   * Debian GNU/Linux 5.0.8 (lenny)   * Don't have admin access, nor physical I've probably missed some other vital statistic or bit of information, in which case I apologize. I'm fairly new to the whole non-Windows side of computing, so I barely know what I'm doing here.


title: How to assign an icon to a program in Openbox?

text: I am running on Arch Linux using Openbox as the window manager. I want to assign icons to some programs that are using the generic icon. This is helpful because when I do an Alt-Tab, I will know the program based on the icon it shows. Currently, I have some programs, like Xterm and Xpdf, using the default icon and doing an Alt-Tab when both are open can be confusing. I have Firefox, Geany and Leafpad installed and I noticed that they have icons during an Alt-Tab. So how do I set this up for the other programs that don't?


title: How to stop firewall from writting logs to /var/log/messages?

text: I'm running OpenSUSE 11.4. The problem is that I can set easily what to log, but not where to log. And currently the same logs are written to `/var/log/firewall` and `/var/log/messages`. I still want messages be written into the first one, but not the second one — it is redundant and it is polluting regular system logs. So how to stop the firewall from writting logs to `/var/log/messages`? I have `/etc/rsyslog.conf`, and its contents are:               ##     ## Note, that when the MYSQL, PGSQL, GSSAPI, GnuTLS or SNMP modules     ## (provided in separate rsyslog-module-* packages) are enabled, the     ## configuration can't be used on a system with /usr on a remote     ## filesystem.     ## [The modules are linked against libraries installed bellow of /usr     ##  thus also installed in /usr/lib*/rsyslog because of this.]     ##     ## You can change it by adding network-remotefs to the Required-Start     ## and Required-Stop LSB init tags in the /etc/init.d/syslog script.     ##          #     # if you experience problems, check     # http://www.rsyslog.com/troubleshoot for assistance     # and report them at http://bugzilla.novell.com/     #          # rsyslog v3: load input modules     # If you do not load inputs, nothing happens!          $ModLoad immark.so     # provides --MARK-- message capability (every 1 hour)     $MarkMessagePeriod     3600          $ModLoad imuxsock.so   # provides support for local system logging (e.g. via logger command)                            # reduce dupplicate log messages (last message repeated n times)     $RepeatedMsgReduction on          $ModLoad imklog.so     # kernel logging (may be also provided by /sbin/klogd),                            # see also http://www.rsyslog.com/doc-imklog.html.     $klogConsoleLogLevel 1 # set log level 1 (same as in /etc/sysconfig/syslog).          #     # Use traditional log format by default. To change it for a single     # file, append ";RSYSLOG_TraditionalFileFormat" to the filename.     #     $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat          #     # Include config generated by /etc/init.d/syslog script     # using the SYSLOGD_ADDITIONAL_SOCKET* variables in the     # /etc/sysconfig/syslog file.     #     $IncludeConfig /var/run/rsyslog/additional-log-sockets.conf          #     # Include config files, that the admin provided? :     #     $IncludeConfig /etc/rsyslog.d/*.conf          ###     # print most important on tty10 and on the xconsole pipe     #     if      ( \                 /* kernel up to warning except of firewall  */ \                 ($syslogfacility-text == 'kern')      and      \                 ($syslogseverity <= 4 /* warning */ ) and not  \                 ($msg contains 'IN=' and $msg contains 'OUT=') \             ) or ( \                 /* up to errors except of facility authpriv */ \                 ($syslogseverity <= 3 /* errors  */ ) and not  \                 ($syslogfacility-text == 'authpriv')           \             ) \     then    /dev/tty10     &       |/dev/xconsole          # Emergency messages to everyone logged on (wall)     *.emerg                                  *          # enable this, if you want that root is informed     # immediately, e.g. of logins     #*.alert                                root          #     # firewall messages into separate file and stop their further processing     #     if      ($syslogfacility-text == 'kern') and \             ($msg contains 'IN=' and $msg contains 'OUT=') \     then    -/var/log/firewall     &       ~          #     # acpid messages into separate file and stop their further processing     #     # => all acpid messages for debuging (uncomment if needed):     #if     ($programname == 'acpid' or $syslogtag == '[acpid]:') then \     #       -/var/log/acpid     #     # => up to notice (skip info and debug)     if      ($programname == 'acpid' or $syslogtag == '[acpid]:') and \             ($syslogseverity <= 5 /* notice */) \     then    -/var/log/acpid     &       ~          #     # NetworkManager into separate file and stop their further processing     #     if      ($programname == 'NetworkManager') or \             ($programname startswith 'nm-') \     then    -/var/log/NetworkManager     &       ~          #     # email-messages     #     mail.*                                  -/var/log/mail     mail.info                               -/var/log/mail.info     mail.warning                            -/var/log/mail.warn     mail.err                                 /var/log/mail.err          #     # news-messages     #     news.crit                               -/var/log/news/news.crit     news.err                                -/var/log/news/news.err     news.notice                             -/var/log/news/news.notice     # enable this, if you want to keep all news messages     # in one file     #news.*                                 -/var/log/news.all          #     # Warnings in one file     #     *.=warning;*.=err                       -/var/log/warn     *.crit                                   /var/log/warn          #     # the rest in one file     #     *.*;mail.none;news.none                 -/var/log/messages          #     # enable this, if you want to keep all messages     # in one file     #*.*                                    -/var/log/allmessages          #     # Some foreign boot scripts require local7     #     local0,local1.*                         -/var/log/localmessages     local2,local3.*                         -/var/log/localmessages     local4,local5.*                         -/var/log/localmessages     local6,local7.*                         -/var/log/localmessages          ###


title: Why is clutter not working?

text: I've managed to install Gnome 3 on Debian testing. However, it is just running in fallback-mode. When want to start mutter or gnome-shell, there seems to be a problem with Clutter:               # mutter --replace     failed to create drawable          (mutter:32069): Clutter-CRITICAL **: Unable to initialize Clutter: Unable to select the newly created GLX context     Fensterverwalter-Fehler:Unable to initialize Clutter.          # gnome-shell --replace     failed to create drawable          (gnome-shell:32182): Clutter-CRITICAL **: Unable to initialize Clutter: Unable to select the newly created GLX context     Fensterverwalter-Fehler:Unable to initialize Clutter.      (Fensterverwalter-Fehler is german and means window-manager error) I know it's not a hardware-issue as I used mutter (and even gnome-shell on another installation) on this notebook. How can I find out which setting is wrong or which package is missing? Thank you in advance! **[edit]** Could gdm be the source of this problem? Because I have gdm (not gdm3) installed. When I install gdm3 the login screen doesn't show me a field to select or input my username, therefore I can't log in.


title: How to measure time of program execution and store that inside a variable

text: In order to find out how long certain operations within a Bash (v4+) script take, I would like to parse the output from the `time` command "separately" and (ultimately) capture it within a Bash variable (`let VARNAME=...`). Now, I am using `time -f '%e' ...` (or rather `command time -f '%e' ...` because of the Bash built-in), but since I already redirect the output of the executed command I'm really lost as to how I would go about to capture the output of the `time` command. Basically the problem here is _to separate the output_ of `time` from the output of the executed command(s). What I want is the _functionality_ of counting the amount of time in seconds (integers) between starting a command and its completion. It doesn't have to be the `time` command or the respective built-in. * * * _Edit:_ given the two useful answers below, I wanted to add two clarifications.   1. I do not want to throw away the output of the executed command, but it will not really matter whether it ends up on stdout or stderr.   2. I would prefer a direct approach over an indirect one (i.e. catching output directly as opposed to store it in intermediate files). The solution using `date` so far comes closes to what I want.


title: Trouble with setting for new monitor

text: I have an old machine with AMD 64 and Radeon VTI graphics. When MS quit supporting XP I partitioned the HD and installed LinuxMint 14 (since upgraded). At the time I was using a 17" ViewSonic monitor. I purchased a new 24" Dell monitor and when I boot up XP it appears to work fine (aspect ratio a bit distorted). When I boot LinuxMint, as soon as I enter my password the monitor goes to mush and the machine locks up. I can go back to the ViewSonic but I'm not sure what to download or do the be able to use the Dell. I am also concerned about changing the settings while using the ViewSonic because it may stop working. Any suggestions?               $ lspci | grep -e VGA -e 3D     01:05.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] RS480 [Radeon Xpress 200 Series]


title: Openwebload installation linux

text: Am trying to install openwebload in Debian. I realize the latest version is pretty old. I used alien to convert the rpm to deb. When trying to run openload as a command however I get this error:               openload: error while loading shared libraries: libstdc++-libc6.2-2.so.3:     cannot open shared object file: No such file or directory      So what I did was to have the current libstdc++ version 6.0 act as the basis for my symbolic link (6.2-2) . That works okay but I encounter this other problem which has been perplexing me.                 undefined symbol: __builtin_vec_new      I do realize this has to do with old library, but I can't find a more recent version of openload.


title: Why can GRUB2 only remember 4 bits?

text: For fun and laziness, I've got 20 entries in my GRUB2 menu. To get to the bottom one quickly, I tap down-arrow a couple of times during the GRUB loading screen. I can press the key 15 times (+/- 1, don't remember) -- the next press, GRUB beeps and the menu choice isn't affected. Why would someone put the limit at 2^4 on a 64-bit processor? Is it even a GRUB problem, or is it caused by keyboard queuing?


title: Failed to boot a fresh FreeBSD 8.2 installation on an Intel SS4200-EHW

text: I've installed FreeBSD on an Intel SS4200-EHW which has four hard disks and a flash DOM (Disk On Module) disk through an IDE interface. I want to install FreeBSD on the Flash DOM. In order to get the FreeBSD installer to find the Flash DOM, I've used the hints from here - by adding the following "hints" before "booting" the installer:               set hint.ata.0.at="isa"     set hint.ata.0.port="0x1F0"     set hint.ata.0.irq="14"      The installer finds the correct disk and installs without any issues. I also made sure the disk/partition is set with the bootable flag. When I boot from the Flash DOM, I get the following error message: "No ufs" and end up with a prompt starting with "boot:". Not sure why this is. Might be that I wasn't able to persist the hint information to any configurations files during the install. Anyone knowing how I can ensure that this get persisted. Any other way to get further to diagnose this issue? **Update** Based on feedback I've included the boot image I am stranded at:![Boot screen image](http://i.stack.imgur.com/wrO9A.jpg) The "tab" key doesn't work. Also I booted PC-BSD to try to edit the files from there and I'm able to mount all other partitions except the boot partition. The image below shows error message when trying to access the MBR partition: ![PC-BSD file browser which shows mounted partitions and the failed partition](http://i.stack.imgur.com/Ph0OP.png)


title: Powersave governor as default Arch

text: I try to change governor from "ondemand" to "powersave" like wiki says ( https://wiki.archlinux.org/index.php/CPU_Frequency_Scaling#Scaling_governors ), but everyway I want to change it, Arch always boot with "ondemand"               sudo cpupower frequency-set -g powersave      by the way this works


title: Whole program name not visible in nethogs

text: I'm using the command `sudo nethogs` to watch network traffic. I have a problem in that the name of the program is too long (it doesn't fit in the PROGRAM column). I haven't found any nethogs configuration switch dealing with this issue. Do you know how to see the whole name of the process?


title: How to rebind XON/XOFF keys?

text: I put `stty -ixon -ixoff` in my `.bashrc` so I can use `Control`+`S` to search the bash history forward (here there is a text about it). However, I sometimes used `Control`+`S` to _really_ send the XOFF signal to the TTY, and would like to be able to still do it but using some other key combination. Is it possible to bind some other key combination in such a way it would send the XOFF signal?


title: Chromium run from within systemd on Fedora 18 does not start

text: Target is building a Linux box, using X, to display commercials (there is a movie in background played by mplayer) and applets (like newsticker, delivered as web apps working locally). I have startup program for the apps, which goes like this (startapps.sh) :               cd /opt/re/scripts          export DISPLAY=":0.0"          XPARA=`/bin/xrandr | awk 'BEGIN { FPAT="[0-9]+"; } / connected / { print $2 " " $3; }'`                  APPDIR='../applets/'             LOGDIR='../logs/'                  APPLIST=`ls $APPDIR`                  for APP in $APPLIST             do                     APPSIZE=`./appsize.php $XPARA $APP`                     APPPOS=`./appsize.php $XPARA $APP 1`                     APPURL="http://localhost/applets/$APP/"                     /bin/screen -d -m /bin/sudo -u rsu /bin/chromium-browser --disable-audio --disable-sync --disable-glsl-translator --disable-translate --disable-web-security --disable-java $APPSIZE --app="$APPURL" &>/dev/null &                     /bin/sleep 1                     /bin/xdotool search --name $APP windowmove $APPPOS             done      Comments: sudo was made to run without terminal already, the screen -d -m approach is a current experiment, it does not work regardless if use screen or not This script WORKS! And then I have systemd service to allow start/stop/reload of this, which goes like this               [Unit]     Description=OTDE Applets     Requires=otde-video.service          [Service]     Environment="DISPLAY=:0.0"     Type=forking     ExecStart=/opt/re/scripts/startapps.sh     ExecStop=/bin/xdotool search --onlyvisible --class chromium windowfocus key alt+F4     ExecReload=/bin/xdotool search --onlyvisible --class chromium windowfocus key ctrl+F5          [Install]     WantedBy=multi-user.target      But running this via the service DOES NOT work. In short   * /path/startapps.sh works, the browser window comes up and gets positioned on display   * service otde-applets start does not work, google chrome outputs the same information on console (whatever it would be) but does not finally show anything on monitor service otde-applest status gives:               Redirecting to /bin/systemctl status  otde-applets.service     otde-applets.service - OTDE Applets               Loaded: loaded (/opt/re/services/otde-applets.service; disabled)               Active: failed (Result: exit-code) since Tue 2013-03-26 22:48:26 CET; 12min ago              Process: 1951 ExecStart=/opt/re/scripts/startapps.sh (code=exited, status=1/FAILURE)          Mar 26 22:48:25 localhost.localdomain systemd[1]: Starting OTDE Applets...     Mar 26 22:48:25 localhost.localdomain sudo[1961]: root : TTY=pts/1 ; PWD=/opt/re/scripts ; USER=rsu ; COMMAND=/bin/chromium-browser --disable-audio --disable-sync --disable-glsl-translator --disable-trans...ets/newsticker/     Mar 26 22:48:26 localhost.localdomain systemd[1]: otde-applets.service: control process exited, code=exited status=1     Mar 26 22:48:26 localhost.localdomain systemd[1]: Failed to start OTDE Applets.     Mar 26 22:48:26 localhost.localdomain systemd[1]: Unit otde-applets.service entered failed state      Thse "status 1" comes out of the xdotool not being able to locate the chrome window I looked at various log files, tried to remove the &>/dev/null to see some more commentary, but unfortunaltely no hints there. Any help or suggestions appreciated.


title: Using grep with symbolic link

text: I don't know how to ask this, but let me explain. I have a text file (named `bla`) in my `~/user/Dropbox` folder. I would like to `grep` on it from any folder in terminal. For example, I'd like just type `grep 'foo' bla` instead of going to `~/user/Dropbox` to look for. I believe that some symbolic link could help. Any idea?


I need to edit my `~/.config/tint2/tint2rc` because the file is blank and so I don't have tint2 shown in my desktop, but when I try to save I have this error:               [ Errore durante la scrittura di /home/alessiomtx/.config/tint2/tint2rc: Non è una directory ]      Translated should be so:               [ Error writing /home/alessiomtx/.config/tint2/tint2rc: Not a directory ]      Solution?


title: File manager multifunction on openbox

text: I've just installed ArchLinux with only OpenBox, I need a file manager and a programme to manage the icons on the desktop. I read that PacManFM can do that, which other filemanager can do each task together?


title: What are the differences between most, more and less?

text: I'm now using Arch Linux, and find a command `most` works like `more` and `less`. To understand the differences between them is a confusing problem. This Question has mentioned the differences between `less` and `more`. Do you know the differences on color performance, shortcuts and ability moving forward and backward?


title: Rsnapshot destination full - how to safely rerun?

text: I ran my Rsnapshot backup today but my external drive became full half-way through the incremental backup (I have about 20 incremental backups now).               rsync: write failed on "<path>": No space left on device (28)      I now have an hourly.0 directory which I assume contains an incomplete incremental backup. How do I recover from this situation without losing data, and redo the backup? My initial thoughts are to:   1. Delete hourly.0 (because it contains an incomplete incremental backup of data since hourly.1 ?)   2. Free up space on the external drive or move the entire contents of my external drive to a larger drive   3. Re-run Rsnapshot. My biggest concern is that deleting hourly.0 will somehow confuse Rsnapshot and cause problems. But is this the right approach?


title: Tried changing to static ip in RedHat 6.5 using VMWare. Unable to access the internet now

text: I followed resources on the internet to assign static ip address for RedHat 6.5 installation in VMWare. I am unable to access the internet after that. My terminal output of the files I changed are as folows:               [Piyush@redhatcdh4_1 ~]$ cat /etc/sysconfig/network-scripts/ifcfg-eth0     DEVICE=eth0     HWADDR=00:0C:29:BE:52:B7     TYPE=Ethernet     UUID=8bd6e426-9bad-4f0c-a098-9345e1d51bfa     ONBOOT=no     NM_CONTROLLED=yes     BOOTPROTO=static     IPADDR=192.168.31.217     NETMASK=255.255.255.0          [Piyush@redhatcdh4_1 ~]$ cat /etc/sysconfig/network     NETWORKING=yes     HOSTNAME=redhatcdh4_1     GATEWAY=192.168.31.2     NTPSERVERARGS=iburst      The output of the ifconfig command is as follows:               [Piyush@redhatcdh4_1 ~]$ ifconfig     eth0      Link encap:Ethernet  HWaddr 00:0C:29:BE:52:B7                 inet addr:192.168.31.217  Bcast:192.168.31.255  Mask:255.255.255.0               inet6 addr: fe80::20c:29ff:febe:52b7/64 Scope:Link               UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1               RX packets:3611 errors:0 dropped:0 overruns:0 frame:0               TX packets:12 errors:0 dropped:0 overruns:0 carrier:0               collisions:0 txqueuelen:1000                RX bytes:226739 (221.4 KiB)  TX bytes:636 (636.0 b)          lo        Link encap:Local Loopback                 inet addr:127.0.0.1  Mask:255.0.0.0               inet6 addr: ::1/128 Scope:Host               UP LOOPBACK RUNNING  MTU:16436  Metric:1               RX packets:601 errors:0 dropped:0 overruns:0 frame:0               TX packets:601 errors:0 dropped:0 overruns:0 carrier:0               collisions:0 txqueuelen:0                RX bytes:46796 (45.6 KiB)  TX bytes:46796 (45.6 KiB)      .               [Piyush@redhatcdh4_1 ~]$ route -n; ping -c3 192.168.31.2; ping -c3 4.2.2.2; cat /etc/resolv.conf     Kernel IP routing table     Destination     Gateway         Genmask         Flags Metric Ref    Use Iface     192.168.31.0    0.0.0.0         255.255.255.0   U     1      0        0 eth0     PING 192.168.31.2 (192.168.31.2) 56(84) bytes of data.     From 192.168.31.217 icmp_seq=1 Destination Host Unreachable     From 192.168.31.217 icmp_seq=2 Destination Host Unreachable     From 192.168.31.217 icmp_seq=3 Destination Host Unreachable          --- 192.168.31.2 ping statistics ---     3 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3003ms     pipe 3     connect: Network is unreachable     # Generated by NetworkManager               # No nameservers found; try putting DNS servers into your     # ifcfg files in /etc/sysconfig/network-scripts like so:     #     # DNS1=xxx.xxx.xxx.xxx     # DNS2=xxx.xxx.xxx.xxx     # DOMAIN=lab.foo.com bar.foo.com      Did I mess up with anything? If you need more data to point out the error, feel free to ask.