title: BSNL 3G USB modem not connecting

text: I am using Arch linux (fully updated). I have been trying to get my BSNL 3G usb modem to work to no avail for the past couple of hours. I have already installed modeswitch, wvdial, modem manager, gnome-ppp, etc but whatever I try throws up some error or the other. When I try wvdial now, this is what I get:               --> WvDial: Internet dialer version 1.61     --> Initializing modem.     --> Sending: ATZ     ATZ     OK     --> Sending: ATQ0 V1 E1 +FCLASS=0     ATQ0 V1 E1 +FCLASS=0     OK     --> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0     ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0     ERROR     --> Bad init string.      When I run modeswitch to maybe change the usage mode of the modem, I get this error :               [venkat@hal9000 ~]$ sudo usb_modeswitch -v 19d2 -p 2003 -u 2     Look for default devices ...        product ID matched     Get the current device configuration ...      Found devices in default mode (1)     Access device 008 on bus 001     Current configuration number is 1     Use interface number 0          USB description data (for identification)     -------------------------     Manufacturer: ZTE,Incorporated          Product: ZTE WCDMA Technologies MSM       Serial No.: MF1800ZTED010000     -------------------------     Change configuration to 2 ...      Device is busy, try to detach kernel driver     Looking for active driver ...      No active driver found. Detached before or never attached      Device is busy, try to detach kernel driver     Looking for active driver ...      No active driver found. Detached before or never attached      Device is busy, try to detach kernel driver     Looking for active driver ...      No active driver found. Detached before or never attached      Device is busy, try to detach kernel driver     Looking for active driver ...      No active driver found. Detached before or never attached      Changing the configuration failed (error -6). Try to continue     -> Run lsusb to note any changes. Bye!      I need some quick help setting this up guys as I will be travelling in a few days. Also, this is my wvdial.conf file :               [Dialer Defaults]     Init1 = ATZ     Init2 = ATQ0 V1 E1 +FCLASS=0     Init3 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0     Password = '9445143977'     Phone = *99#     Modem Type = Analog Modem     Stupid Mode = 1     Baud = 9600     Dial Command = ATDT     Modem = /dev/ttyUSB1     ISDN = 0     Username = '9445143977'     Auto Reconnect = off


title: Conflict between my prompt definition and cat in zsh

text: I have a file on a remote filesystem that I know has a short text string in it (a sequence of numbers in a single line). If I open the file on a text editor like nano or Emacs I can see the string. Also, not sure if this is relevant, but `ls` reports the file has 8 bytes*. The odd thing is that if I `cat` this file, `cat` reports nothing. However, I noticed that if I add a linebreak at the end of the line, `cat` then shows the contents, which is confusing me. So my questions are:   * Why does this happen? Do I really need a linebreak at the end of each line to have `cat` print its contents? Is this the default behavior for `cat`? (if so, what is the reasoning behind it?)   * Is there a way to force `cat` to print everything in a file, regardless of whether or not I have linebreaks? ## Update: Based on the answers below, I thought it would be relevant to post how I defined my prompt. I'm on `zsh`, and I have the following **two lines** on my `~/.zshrc`:               export PS1="%{$fg[white]%}%n%{$reset_color%} @ %{$fg[green]%}%m: %{$fg[yellow]%}%~ %{$reset_color%}%%     > "      Before the definition of my prompt, I have the following two lines which I believe enable me to use color aliases in the shell:               autoload -U colors     colors      ### Rephrasing the question: With the above in mind, how can I get a linebreak in my prompt, and still manage to get `cat` to print a file like the above correctly? * * * *If I `touch` a random file, `ls` reports the file has only 0 bytes, so I presume that the fact that `ls` reports that my file has 8 bytes is meaningful. Not sure if this is helpful though.


title: ls command operating differently depending on recipient

text: How does commands like `ls` know what its stdout is? It seems `ls` is operating different depending on what the target stdout is. For example if I do:               ls /home/matt/tmp       the result is:               a.txt b.txt c.txt      However if I do               ls /home/matt/tmp | cat      the result is (i.e. new line per result):               a.txt     b.txt     c.txt      The process is passed a file descriptor 1 for stdout right? How does it determine how to format the result? Does the file descriptor reveal information?


title: Backing up a partition: doesn't reflect the status properly

text: With an intent to check how backing up files/filesystems works, I created 3 part itions sda9, sda10 and sda11. Please see the structure below. (Please ignore sda10 for now as I have already run command to back up sda9 onto it)               ravbholua@ravbholua-Aspire-5315:~/mount$ df -h     Filesystem      Size  Used Avail Use% Mounted on     /dev/sda6       9.9G  6.5G  2.9G  70% /     none            4.0K     0  4.0K   0% /sys/fs/cgroup     udev            489M   12K  489M   1% /dev     tmpfs           100M  936K   99M   1% /run     none            5.0M  4.0K  5.0M   1% /run/lock     none            497M  156K  497M   1% /run/shm     none            100M   36K  100M   1% /run/user     /dev/sda5       284M  177M   93M  66% /boot     /dev/sda8       9.5G  7.5G  1.6G  84% /home     /dev/sda11      1.2G  1.8M  1.1G   1% /home/ravbholua/mount/mount11     /dev/sda9        21M  181K   19M   1% /home/ravbholua/mount/mount9     /dev/sda10       64Z   64Z  4.6G 100% /home/ravbholua/mount/mount10      For my test, I entered the directory where sda9 was mounted. I created a few files and directory tree. Then I ran the below command to backup sda9 on sda11               sudo dd if=/dev/sda9 of=/dev/sda11      Now please see how the structure looks:               ravbholua@ravbholua-Aspire-5315:~/mount/mount11$ df -h     Filesystem      Size  Used Avail Use% Mounted on     /dev/sda6       9.9G  6.5G  2.9G  70% /     none            4.0K     0  4.0K   0% /sys/fs/cgroup     udev            489M   12K  489M   1% /dev     tmpfs           100M  948K   99M   1% /run     none            5.0M     0  5.0M   0% /run/lock     none            497M  160K  497M   1% /run/shm     none            100M   40K  100M   1% /run/user     /dev/sda5       284M  177M   93M  66% /boot     /dev/sda8       9.5G  7.5G  1.6G  84% /home     /dev/sda11       37M -1.1G  1.2G    - /home/ravbholua/mount/mount11     /dev/sda9        21M  181K   19M   1% /home/ravbholua/mount/mount9     /dev/sda10       64Z   64Z  4.6G 100% /home/ravbholua/mount/mount10     ravbholua@ravbholua-Aspire-5315:~/mount/mount11$ ls     ravbholua@ravbholua-Aspire-5315:~/mount/mount11$       I'm unable to get why sda11 shows as above. Also I was expecting that when I enter the directory where sda11 is mounted (as shown in the above code, last but one line), it would reflect the contents of sda9 but it was blank. Why so !! What have I misunderstood? The same happened when I ran the above back up command to back up sda9 on sda10 and hence sda10 shows as above `/dev/sda10 64Z 64Z 4.6G 100% /home/ravbholua/mount/mount10`. What's that Z!! It shows use % as 100 % but still showing 4.6G as available!! What's all these? ### EDIT #1 I rebooted and found the 3 new partitions on the launcher of my Ubuntu desktop. I mounted by clicking them and I found the 2 partitions sda10 and sda11 are clones of sda9. Hence the back-up has worked fine. Please look below the output of `df -h` now:               ravbholua@ravbholua-Aspire-5315:~$ df -h     Filesystem      Size  Used Avail Use% Mounted on     /dev/sda6       9.9G  6.5G  2.9G  70% /     none            4.0K     0  4.0K   0% /sys/fs/cgroup     udev            489M  8.0K  489M   1% /dev     tmpfs           100M  952K   99M   1% /run     none            5.0M  4.0K  5.0M   1% /run/lock     none            497M  260K  497M   1% /run/shm     none            100M   44K  100M   1% /run/user     /dev/sda5       284M  177M   93M  66% /boot     /dev/sda8       9.5G  7.5G  1.6G  84% /home     /dev/sda9        21M  181K   19M   1% /media/ravbholua/c583223f-8dea-4dc0-b433-caff722eda68     /dev/sda10       21M  181K   19M   1% /media/ravbholua/c583223f-8dea-4dc0-b433-caff722eda681     /dev/sda11       21M  181K   19M   1% /media/ravbholua/c583223f-8dea-4dc0-b433-caff722eda682      Please look at the new sizes of sda10 and sda11. As per the command output, they have lost their original size and taken the size of sda9. (Repeating that sda9 was backed-up to both sda10 and sda11). All 3 have become perfectly the same. For the exact sizes, please look at the gparted below. Here I would like to know why gparted shows differently than what `df -h` showed. For example, `df -h` shows size of sda11 as 21M but gparted shows the actual size 1.17GB, i.e. the size that was created. Why both (gparted and "df -h") differ from each other and which one to accept? ![enter image description here](http://i.stack.imgur.com/2N2bY.png)


title: What happens when your password expires and you're using key authentication?

text: on one of the boxes I don't control at work I use `ssh` keys to log in. Our passwords are set to expire after a few months. What happens if I don't reset my password and it expires? will I still be able to login? Does what happens depend on some `sshd` setting? or some pam setting?


Is there any way to keep a command from being added to your history? I have a command that I want to keep out of my history file, and I really don't care to have it there when I search the history stored in memory, though that's less of a concern. Is there any way to prevent this, or do I just have to go back and edit my history file. **update:** I didn't realize this might be shell-specific. My shell is `zsh`. You're welcome to answer for other shells so people know how to do this in their shell.


title: Can I spawn a new terminal that is a clone of the current terminal?

text: So let's say I'm developing code in directory /asdf/qwer/dfgh/wert/asdf/qwer and I've added about three more directories like that to my path and I have a bunch of arcane environment variables set. Then I realize that I really need another terminal open and set up in just this same way (although this need is not reoccurring so that I would just alter my .bashrc). Is there any command to open a new terminal window that is an exact clone of this one?


title: How to atomically change / rotate log file every minute?

text: I've got a legacy app that is generating a huge lot of logs message. I'd like to be able to rotate the file every minute (or so) but without loosing / truncating any message. The app is not able to change of file by itself so I need to do it externally. Surfing the net I've seen a lot of suggestion to use `cp` followed by a `cat /dev/null` but since my app is generating almost a continuous flow of messages some messages are lost during the process. Do you have any ideas ?


title: Prevent or detect reading of daemon in memory

text: Is it possible to prevent the memory being used by a daemon to be read by anything else? If not, is it possible to detect an attempt to read? If so, is it possible to get in front of the actual read and execute commands that can act first?


title: Why does export -p exclude $_ variable?

text: As far I know, there are 3 ways to see exported variables:               $ export -p | wc -l     50     $ env | wc -l     51     $ printenv | wc -l     51      As you can see, `export -p` misses single variable. It's a `$_` one:               $ diff <(export -p |sed 's/declare -x //' | sed 's/"//g' | sort) <(printenv | sort)     41a42     > _=/usr/bin/printenv      `$_` is special variable set to final argument of previous command executed. Why `export -p` doesn't include it, unlike two other commands? **Edit** I understand that exporting `$_` might not have any sense but if `$_` is not exported then why it appears in `printenv` output? `printenv` prints environment variables, environment variables are exported ones, `$_` is not exported. Am I missing something here?


title: initrd or ramfs for SLES as /

text: i would like to boot a SLES and run it out of a ramdisk. I would like to setup machines so that they start PXE boot and as part of the PXE boot process they pull across an image that is the root filesystem and then boot this. Has anyone done this or similar yet? My thinking is that the `initrd` is almost what i want to have although far too small and short on features. So i did a minimal install and then did a cpio of this to create my own custom `initd`. (This is about 350M, which although big is fine for this purpose). It has trouble booting up at the point when it tries to `fsck` the `/dev/shm/root`. What is the correct way to stop this happening (I tried by setting in `/etc/fstab`, but no good). As next option I set a sysconfig file to force READONLYROOT and this got me booting the init process as far as the point where it switches to `/etc/init.d/rc3.d` but now I cant get it to go further. Any advice or ideas or if someone else has done this they that would all be great. PS. Setup is big nodes with 1TB RAM and I don't want to have local filesystem for OS and the alternative is to have NFS server the root filesystem, but I don't want the NFS traffic so RAM disk seems like good option.


title: How can I automatically load my config file in Grub2?

text: I've installed grub2 because my partition is no longer supported by the legacy grub but I can't make it display a text menu like in the legacy grub? When I start my pc it gives me the CLI where I need to manually load my configfile? Hence my config file is good but how I can start it automatically with grub2? My OS is openSUSE and I use grub2-mkconfig --output=/boot/grub2/grub.conf to create my config file. Then I use grub2-install /dev/sda2 to install grub2. I've also edited /etc/default/grub to display the menu and commented hideoutmenu line. Please help because this is very anoying bug? Thank you very much! Update: Please read the question I've openSUSE and Linux is a bit weird. I already tried grub2-mkconfig -o /boot/grub2/grub.conf. I also tried it with grub.cfg. There isn't grub-mkconfig only grub2-mkconfig. There isn't also update-grub (or update2-grub). This is a script that doesn't exist in openSUSE!!?! Update 2: Maybe it's a video card problem? Windows Os is recognized from my grub2-mkconfig: http://ubuntuforums.org/showthread.php?t=1485072&page=3 Update 3: I also get this error message when I use --force:               /usr/sbin/grub2-bios-setup: Warnung: Dateisystem »ext2« unterstützt keine        Einbettungen.     /usr/sbin/grub2-bios-setup: Warnung: Einbettung ist nicht möglich. GRUB       kann in dieser Konfiguration nur mittels Blocklisten installiert werden.      Blocklisten sind allerdings UNZUVERLÄSSIG und deren Verwendung wird daher      nicht empfohlen..     installation beendet. Keine Fehler aufgetreten.      Update 4:                 grub2-mkconfig --output=/boot/grub2/grub.cfg       grub.cfg wird erstellt …       Linux-Abbild gefunden: /boot/vmlinuz-3.4.4-1.1-desktop       initrd-Abbild gefunden: /boot/initrd-3.4.4-1.1-desktop          No volume groups found       Windows 7 (loader) auf /dev/sdc1 gefunden       erledigt      Update 5: As requested I use /dev/sda instead of /dev/sda2 and it works better, I don't need --force command.                  grub2-install --boot-directory=/boot/grub2 /dev/sda        installation beendet. Keine Fehler aufgetreten.      But in this README there is the script update-grub2: https://build.opensuse.org/package/view_file?file=README.openSUSE&package=grub2&project=openSUSE%3AFactory&rev=c3401e0f5ec23451c03caa9b77fa0d99 But I don't have it? Update 6:               # If you change this file, run 'grub2-mkconfig -o /boot/grub2/grub.cfg'          afterwards to update      # /boot/grub2/grub.cfg.     GRUB_DISTRIBUTOR="openSUSE"          GRUB_DEFAULT=2     #GRUB_HIDDEN_TIMEOUT=0     GRUB_HIDDEN_TIMEOUT_QUIET=true     GRUB_TIMEOUT=5     GRUB_CMDLINE_LINUX_DEFAULT="quiet splash=silent"     GRUB_CMDLINE_LINUX=""          # Uncomment to enable BadRAM filtering, modify to suit your needs     # This works with Linux (no patch required) and with any kernel that obtains     # the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)     #GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"          # Uncomment to disable graphical terminal (grub-pc only)     #GRUB_TERMINAL=console          # The resolution used on graphical terminal     # note that you can use only modes which your graphic card supports via VBE     # you can see them in real GRUB with the command `vbeinfo'     GRUB_GFXMODE=800x600          # Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to        Linux     GRUB_DISABLE_LINUX_UUID=true          # Uncomment to disable generation of recovery mode menu entries     #GRUB_DISABLE_LINUX_RECOVERY="true"          # Uncomment to get a beep at grub start     #GRUB_INIT_TUNE="480 440 1"     GRUB_BACKGROUND=/boot/grub2/themes/openSUSE/background.png     GRUB_THEME=/boot/grub2/themes/openSUSE/theme.txt      Update 7: My file grub-mkconfig_lib is also in /usr/share/grub2 and not in /usr/lib/grub: http://forums.opensuse.org/english/get-technical-help-here/pre- release-beta/476722-grub2-broken-12-2-rc1.html? Update and Fix:   1. Error: In my grub config file this line GRUB_HIDDEN_TIMEOUT_QUIET=true change to GRUB_HIDDEN_TIMEOUT_QUIET=false and comment this line #GRUB_HIDDEN_TIMEOUT=0.   2. Error: It only works from /boot and NOT from /boot/grub2 although /boot/grub2 is the default path everywhere. Strange. Maybe it's because I'm using AHCI???


title: An oom killer thats baffling me

text: I am not able to understand why would kernel issue this oom killer when I see enough memory is available: Also why are there so many kernel cache pages allocated? I say enough memory is available after looking at Normal DMA Normal free lines This is an embedded nand flash based device with 256 MB RAM Kernel : 2.6.31                myshellscript invoked oom-killer: gfp_mask=0xd0, order=2, oomkilladj=0       Backtrace:       [<c0106494>] (dump_backtrace+0x0/0x110) from [<c03641a0>] (dump_stack+0x18/0x1c)       r6:000000d0 r5:c9040c60 r4:00000002 r3:c0448690       [<c0364188>] (dump_stack+0x0/0x1c) from [<c015a314>] (oom_kill_process.clone.11+0x60/0x1b4)       [<c015a2b4>] (oom_kill_process.clone.11+0x0/0x1b4) from [<c015a738>] (__out_of_memory+0x154/0x178)       r8:c21e86e0 r7:001fb000 r6:00000002 r5:000000d0 r4:c9b6e000       [<c015a5e4>] (__out_of_memory+0x0/0x178) from [<c015a980>] (out_of_memory+0x68/0xa0)       [<c015a918>] (out_of_memory+0x0/0xa0) from [<c015d230>] (__alloc_pages_nodemask+0x42c/0x520)       r5:00000002 r4:000000d0       [<c015ce04>] (__alloc_pages_nodemask+0x0/0x520) from [<c015d388>] (__get_free_pages+0x18/0x44)       [<c015d370>] (__get_free_pages+0x0/0x44) from [<c0109418>] (get_pgd_slow+0x1c/0xe0)       [<c01093fc>] (get_pgd_slow+0x0/0xe0) from [<c0129ab0>] (mm_init.clone.43+0xb0/0xf0)       r7:c90858c0 r6:00000000 r5:c90858c0 r4:ce1a6680       [<c0129a00>] (mm_init.clone.43+0x0/0xf0) from [<c0129c40>] (mm_alloc+0x34/0x44)       r6:0009230c r5:c90858c0 r4:ce1a6680 r3:00000000       [<c0129c0c>] (mm_alloc+0x0/0x44) from [<c0180f70>] (bprm_mm_init+0x14/0x148)       r4:c5154000 r3:cd472564       [<c0180f5c>] (bprm_mm_init+0x0/0x148) from [<c01812d0>] (do_execve+0xa8/0x254)       [<c0181228>] (do_execve+0x0/0x254) from [<c0106000>] (sys_execve+0x3c/0x5c)       [<c0105fc4>] (sys_execve+0x0/0x5c) from [<c0102e80>] (ret_fast_syscall+0x0/0x2c)       r7:0000000b r6:0009230c r5:0009237c r4:000922fc       Mem-info:       DMA per-cpu:       CPU 0: hi: 18, btch: 3 usd: 0       Normal per-cpu:       CPU 0: hi: 42, btch: 7 usd: 0       Active_anon:28162 active_file:16 inactive_anon:18037       inactive_file:13 unevictable:0 dirty:0 writeback:0 unstable:0       free:9998 slab:2447 mapped:164 pagetables:701 bounce:0       DMA free:17128kB min:1560kB low:1948kB high:2340kB active_anon:51068kB inactive_anon:10320kB active_file:24kB inactive_file:0kB unevictable:0kB present:97536kB pages_scanned:0 all_unreclaimable? no       lowmem_reserve[]: 0 158 158       Normal free:22864kB min:2600kB low:3248kB high:3900kB active_anon:61580kB inactive_anon:61828kB active_file:40kB inactive_file:52kB unevictable:0kB present:162560kB pages_scanned:0 all_unreclaimable? no       lowmem_reserve[]: 0 0 0       DMA: 2358*4kB 912*8kB 25*16kB 0*32kB 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB 0*8192kB 0*16384kB = 17128kB       Normal: 4266*4kB 657*8kB 32*16kB 1*32kB 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB 0*8192kB 0*16384kB = 22864kB       26591 total pagecache pages       0 pages in swap cache       Swap cache stats: add 0, delete 0, find 0/0       Free swap = 0kB       Total swap = 0kB       65536 pages of RAM       10471 free pages       3967 reserved pages       2447 slab pages       892 shared page count       389 shared pages      620 mapped shared page count      177 mapped shared pages      0 pages swap cached      2481 dma reserved pages      19892 total user pages      20512 RSS sum by tasks      20512 RSS sum by page stats      164 user cache pages      26427 kernel cache pages


title: Adding ssh on embedded linux

text: I want to run SSH on Qtopia (on my FriendlyARM). My own distribution is Ubuntu, so I cannot copy and paste the ssh binary file into the device. If I can copy and paste a binary file, where can I find it? If I must compile SSH, how is it possible in my ubuntu?


title: Password protecting a system file? (e.g. /etc/resolv.conf)

text: I am trying to parental control myself by restricting web access via OpenDNS. The OpenDNS account password will be handed to someone trustworthy. Now, I want to put some restriction on the /etc/resolv.conf, perhaps using a key or password, but not the root password. Also I do not want to compromise the accessibility by the kernel. Is this possible?


title: Install application on barebone linux board without internet

text: I'm kind of new to using linux for hardware development. I made a C program which uses ExifTool, and it works fine on the desktop. The ExifTool have to be installed and runs on Perl. I can cross compile my program to my board (TI video processor), but it doesn't have perl or anything to begin with. So how can I get this to work? The board doesn't have internet, but I can transfer with SD card. Essentially I need:   * Install Perl (no clue how)   * Install ExifTool (I have the files)   * install 'make' function (to install the ExifTool from the files) Or if anyone is familiar with ExifTool, is there any way I can make it completely stand alone?


title: Linuxwacom xsetwacom/xorg.conf

text: I have a CentOS 6.2 workstation with linuxwacom 0.21.0 installed. I am trying to map a button on a cintiq tablet to a keyboard key. I can do it successfully using:               xsetwacom set "Wacom Cintiq 24HD pad" Button 8 "key f11"      However, the tablet is connected to a kvm so it is frequently 'disconnected' and 'reconnected'. This means that the key mapping resets. I have tried setting it in `/usr/share/X11/xorg.conf.d/50-wacom.conf` using:               Option "Button8" "key f11"      (I also tried "Button 8") but then I get this error in `Xorg.0.log`:               (WW) Option "Button8" requires an integer value      Is it not possible to map tablet buttons to keyboard buttons in the `xorg.conf` settings? If that's not possible is there an alternative way that I can map the keys every time the tablet is connected?


title: USB Ports not working with Ubuntu Linux 14

text: Sorry if this seems like a duplicate post but I am Ubuntu Linux noob and am struggling with it a bit. I installed and configured Ubuntu Linux 14 for dual boot setup on my Windows 8.1 machine. Everything is working fine except for 2.0 USB ports. They simply don't do anything when I plug either a plain old USB stick, or even my USB mouse. I read about lsusb, and below is the output.               jason@JasonsUbuntu:~$ lsusb     Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub     Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub     Bus 001 Device 005: ID 05ca:18c4 Ricoh Co., Ltd      Bus 001 Device 004: ID 0489:e036 Foxconn / Hon Hai      Bus 001 Device 003: ID 04f3:002d Elan Microelectronics Corp.      Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub     Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub     Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub     Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub      I can tell that the 2.0 USB ports are 'registered' (not sure what linux terminology is for that) but they just seem to be dead ports. Where can I go from here to further troubleshoot the issue? **Edit:** Here's the output from lsusb -t, I hope this new information is useful.               jason@JasonsUbuntu:~$ lsusb -t     /:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 5000M     /:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M     /:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=ehci-pci/2p, 480M         |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/6p, 480M     /:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci-pci/2p, 480M         |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/6p, 480M             |__ Port 1: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 12M             |__ Port 2: Dev 4, If 0, Class=Wireless, Driver=btusb, 12M             |__ Port 2: Dev 4, If 1, Class=Wireless, Driver=btusb, 12M             |__ Port 3: Dev 5, If 0, Class=Video, Driver=uvcvideo, 480M             |__ Port 3: Dev 5, If 1, Class=Video, Driver=uvcvideo, 480M


title: Is FreeBSD license easier than Ubuntu/Fedora/CentOS/ArchLinux when it comes to GPL + Close source + Sell?

text: If I use FreeBSD/OpenSolaris, and stop using Ubuntu/Fedora/CentOS/ArchLinux, migrate my all applications to FreeBSD/OpenSolaris will that reduce license problems? Specially, GPL/LGPL is very complicated combination, and specially it turns out to be that Linux distro licenses are very complicated then Unix licenses? (please correct me if i am wrong) Seems like FreeBSD allows to sell and also allowes to make closed source where Linux GPL license is most confusing when it comes to sell the product for derived works. I was reading this article which, scares me that those guy can reject anyone just with a single tiny word mistake: http://projects.opensource.org/pipermail/license- discuss/2011-December/000039.html


title: Makefile error: empty variable name

text: I am writing a simple Hello World kernel module. The Makefile I wrote is giving me such an error:               esp@ubuntu:~/task1-2$ make all          make -C /usr/src/linux-headers-3.13.0-35-generic SUBDIRS = /home/esp/task1-2 modules     make: ****** empty variable name.  Stop.     make: ** [all] Error 2      How do I rectify it? My Makefile:               obj-m += task1-2.o          KDIR = /usr/src/linux-headers-3.13.0-35-generic               all:         $(MAKE) -C $(KDIR) SUBDIRS = $(PWD) modules          clean:         rm -f *.o         rm -f *.ko         rm -f *.mod.*         rm -f *.symvers         rm -f *.order


title: New SuSE install intermittently freezes

text: I've just installed the latest Gnome SuSE from their website (downloaded from their site yesterday). I grabbed the LiveCD, put it on a USB stick, booted from it, and used the included installer to install onto a freshly wiped drive. The installation wemt smoothly. No errors, package updates all worked, ran Yast to configure the wired network connection and everything was off and running. The only additional change I've made was to go into the display settings and turn off mirroring for my second monitor. Now, the machine intermittently freezes a minute or so after boot. The mouse sort of works - if I move it, it'll respond 10-30 seconds later. I can initally hit Ctrl+Alt+F1 to get to a console, but that also freezes after a few seconds. I can hit Ctrl+Alt+F7 to get back to Gnome, but then even the intermittent mouse will not respond. The only option at that point is a hard reboot via the reset button on the case. This is a custom machine with a P51 motherboard, i7 quad core, 16GB of RAM, 2x GTX580s (I haven't changed the video driver from what the installer auto- configured), and a 1TB drive with no other operating systems. I previously had Win7 Ultimate x64 running for over a year with no difficulties, which leads me to believe that this is not a hardware problem. Any suggestions on where to start looking? I'm comfortable with the shell and normal app installation, etc., but am not really a Linux expert. **Update** After leaving it frozen for a few minutes, I saw this: ![enter image description here](http://i.stack.imgur.com/CxwKg.jpg) And later, the messages:               [  OK  ] Started LSB: VMware Tools Daemon     [  OK  ] Started LSB: X Display Manager      Any help would be greatly appreciated.


title: Regular expression in bash script

text: This is my first time bash scripting so I'm probably making an easy mistake. Basically, I'm trying to write a script that gets the groups of a user, and if they are in a certain group, it will log that accordingly. Evidently there will be more functionality, but there's no point building that when I can't even get the regex working! So far, I have this:               #!/bin/bash          regex="^([a-zA-Z0-9\-_]+ : [a-zA-Z0-9\-_]+) (usergroup)$"          # example output     groups="username : username usergroup"          echo "$groups" >> /home/jrdn/log          if [[ "$groups" =~ $regex ]]; then         echo "Match!" >> /home/jrdn/log     else         echo "No match" >> /home/jrdn/log     fi      Every place I've tried that regex, it works. But in the bash script, it only ever outputs the `$groups`, followed by `No match`. So can someone tell me what's wrong with it?


title: Fedora 18 - Start sshd on boot

text: I've just installed Fedora 18, and trying to configure `sshd` - I used `chkconfig` but this is only starting `sshd` when a user is logged in. How do I change so that `sshd` starts on system boot?


title: CentOS 6 and Fedora Repositories

text: I did a Google search and couldn't find the specific answer to my questions. I know CentOS and Fedora are extremely similar. Would a Fedora repository (i.e. https://www.google.com/intl/en/chrome/browser/?hl=en&platform=linux&brand=CHFK) work for CentOS? Are there any risks for attempting to install a Fedora repo on CentOS 6?


title: Open a command line window in GNOME Desktop

text: In GNOME Desktop, when I type `/usr/bin/firefox`, the Firefox browser will open. How can I open a command line window in the same way?


title: Using sed to extract text between 2 tags

text: I have a .xml file and I'm trying to do a "groupinstall" on a RHEL6 machine as there are several hundred libraries in that .xml file... (close to 16 000 lines). I'm therefore trying to extract the group names contained in the .xml file that has this structure:               <b>     <group>     <id> group name </id>        <packages>        ...        </packages>     <id> group name 2 </id>        <packages>        ...        </packages>     <id> etc... </id>     </group>     </b>      Basically, this is what I've tried:               sed -n '/<id>/,/<\/id>/p' test1.txt > test2.txt      I copied the .xml file to test1.txt. I'm trying to extract the group names from the test1.txt to a second file called test2.txt. However, with the line above, it is extracting everything from the FIRST `<id>` tag to the last `</id>` tag in my file. How can I change my code to extract it several times? My second question would be: does the -downloadonly plugin work as well with groups for yum?


title: Changing gVim behaviour on Red Hat

text: I recently had to change my Linux work environment from a personal Ubuntu system (having full admin rights) to a corporate Red Hat system (having very limited control on the system). Both running GNOME. Many things seem to work differently. Above all is the gVim behaviour. I have Vim installed on two Linux machines and one Windows machine. I like the default Windows behaviour, so I set the `.gvimrc` file as follows:               source $VIMRUNTIME/mswin.vim          syn on     set hls     set tabstop=4     set shiftwidth=4     set smartindent     set smarttab      Some annoying differences I experience, between Red Hat and Ubuntu or Windows are:   1. The undo (`Ctrl`+`Z` or Undo button) is acting like in Vi, that is 2nd undo, undoes the 1st one, so the last change is removed and then restored. Instead, it should be an undo history (up to the `undolevel` variable setting)..   2. When in `Insert` mode, deleting text with the backspace key does not remove the deleted text from the screen, until I either move away from that line or exit `Insert` mode. The following variables are set similarly in Red Hat and Windows:               nocompatible       undodir=.     noundofile       undolevels=1000       undoreload=10000      Question: How can I make my new Red Hat gVim environment behave like the Windows and Ubuntu one? Vim versions: Red Hat - 7.4 (Aug 10, 2013)   Windows - 7.4 (Aug 10, 2013)   Ubuntu - 7.2 (Aug 9, 2008)


title: Capture raw image from V4L (webcam) device

text: I'm using a Raspberry pi to monitor a self-service fridge. When the door opens, a shell script is being executed to capture pictures until the door closes again. The problem, however, is the speed of the ARM-processor. Capturing in full resolution using fswebcam takes 2-4 seconds, which is too long. Our idea to solve this is to split the process:   1. Capture raw images and save to memory card   2. After the door is closed, process the raw data. This is not time-critical. Now, my questions are:   1. Is this possible / wise?   2. Which program should I use?


title: GNOME-keyring KWallet integration?

text: I use some GNOME apps, and some KDE apps, so some of them use G-keyring and some KWallet... What I would like to have is a single place for managing passwords. Is there a way to integrate G-keyring and KWallet? Or is there maybe a way to force GNOME apps to use KWallet or KDE apps to use G-keyring? OR is there maybe a way to force them all to use KeePassX or something similar (automaticaly using it after entering the master password)...?


title: Limit access on external drive mounted and used by sftp

text: I've got a unix user "popolo" who is chrooted in `/srv/ftp/` and I mount my two external drives by `/etc/fstab` in `/srv/ftp` so I have `/srv/stp/dude` and `/srv/ftp/sweet`. Popolo has access to those drives by sftp. In `dude/` I've several directories: `dude/music`, `dude/photos`, `dude/movies`, and for some of them (like photos) I don't want that popolo can access to them. Is using `/etc/fstab` and a user chrooted via sftp is the best way to do this ? How can I restrict access to some directories ?


title: 802.3ad on FreeBSD and Linux using crossover cables?

text: I have setup a NFS server on FreeBSD 8.1, which will be serving one Linux client. Each box has a dual-port 1gig fiber card, and each box is directly connected to the other over this link. There is no switch involved. I suppose that my question is, since both FreeBSD and Linux support 802.3ad, is the following the right way to configure this, when not using a switch? Or is there a better way? Is this even supported? With this setup, I am able to ping between the hosts, transfer files over NFS, etc.               FreeBSD  em2 <-> eth2 Linux               em3 <-> eth3      I have configured em2 and em3 for 802.3ad (lacp):               lagg0: flags=8843 metric 0 mtu 1500      options=9b      ether 00:04:23:c2:c2:e0      inet 192.168.0.1 netmask 0xfffffffc broadcast 192.168.0.3      media: Ethernet autoselect      status: active      laggproto lacp      laggport: em3 flags=1c      laggport: em2 flags=1c                    if_lagg_load="YES"     ifconfig_em2="UP"     ifconfig_em3="UP"     #ifconfig_lagg0="create"     cloned_interfaces="lagg0"     ifconfig_lagg0="laggproto lacp laggport em2 laggport em3 192.168.0.1 netmask 255.255.255.252"      And eth2 and eth3 for 802.3ad bonding:               [root@xbox ~]# ifconfig bond0     bond0     Link encap:Ethernet  HWaddr 00:04:23:C2:C4:DA                 inet addr:192.168.0.2  Bcast:192.168.0.3  Mask:255.255.255.252               inet6 addr: fe80::204:23ff:fec2:c4da/64 Scope:Link               UP BROADCAST RUNNING MASTER MULTICAST  MTU:1500  Metric:1               RX packets:140000208 errors:0 dropped:0 overruns:0 frame:0               TX packets:101560577 errors:0 dropped:0 overruns:0 carrier:0               collisions:0 txqueuelen:0                RX bytes:3281219872 (3.0 GiB)  TX bytes:3609990240 (3.3 GiB)                    [root@xbox network-scripts]# cat ifcfg-bond0      DEVICE=bond0     IPADDR=192.168.0.2     NETWORK=192.168.0.0     NETMASK=255.255.255.252     USERCTL=no     BOOTPROTO=none     ONBOOT=yes     [root@xbox network-scripts]# cat ifcfg-eth2     DEVICE=eth2     USERCTL=no     ONBOOT=yes     MASTER=bond0     SLAVE=yes     BOOTPROTO=none     [root@xbox network-scripts]# cat ifcfg-eth3     DEVICE=eth3     USERCTL=no     ONBOOT=yes     MASTER=bond0     SLAVE=yes     BOOTPROTO=none     [root@xbox network-scripts]# tail -n2 /etc/modprobde.conf     alias bond0 bonding     options bond0 mode=802.3ad miimon=100      _EDIT_ : I've found that, on the FreeBSD box, the MAC addresses of em2 and em3 are the same, where-as on the Linux box, the MAC addresses of eth2 and eth3 are different.


title: Using 'convert' with files that has space characters?

text: for f in $(ls mydir/*.jpg)     do          convert -thumbnail $size -quality $quality $f thumbsdir/$(basename $f)     done      I'm trying to code a script that takes a directory with images and generates thumbnails from these images. The script runs well, but when it gets to image files that include space characters, it gives me errors, because it thinks it's another file when it meets the space character. I already tried using quotes such as:               convert -thumbnail $size -quality $quality "$f" "thumbsdir/$(basename $f)"      ...but no success. How could I make this work without having to rename all files and remove space characters?


title: Connecting BeagleBoard-xm OS Angstrom direct to Laptop ubuntu 12.04

text: I have BeagleBoard-xm with Angstrom OS. My Laptop's OS is Ubuntu 12.04. I managed to connect Laptop to another Laptop, direct through crossover cable. I wanted to connect BeagleBoard-xm to the Laptop direct through crossover cable. BeagleBoard-xm OS Angstrom command,ifconfig, doesn't show the MAC address. How should I configure OS Angstrom? Regards


title: How do I distribute a large download over multiple computers?

text: I need to download a large file (1GB). I also have access to multiple computers running Linux, but each is limited to a 50kB/s download speed by an admin policy. How do I distribute downloading this file on several computers and merge them after all segments have been downloaded, so that I can receive it faster?


title: Monitor com port with strace

text: I have done small application in Java that writes to com port two strings -'dddd' and 'ffff'. I decided to look how it writes with thelp of `strace -s9999 -o serialtrace.log -eread,write,ioctl` And I got log in which I found that com port descriptor is `5`. Tgis is filtered output:               Line 112: read(5, "#\n#Tue Jan 14 12:28:06 GMT+01:00 2014\ncurrencyCode=440\nlogFileName=dbg.log\nport=4462\ncommunicationForward=true\nterminalLanguage=4\ntermInterfaces=\ndelLogDaysOld=0\nStopBits=1\nParity=0\nmessagesFileName=language.ini\nDataBits=8\ncomPort=/dev/ttyS0\nInfoInReceiptSlip=1\ntermDataEncoding=1\nBaudRate=9600\nDebugRX=true", 8192) = 311     Line 113: read(5, "", 8192)                       = 0     Line 114: read(5, "", 8192)                       = 0     Line 222: read(5, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0P/\0\0004\0\0\0x4\2\0\0\0\0\0004\0 \0\4\0(\0\34\0\31\0\1\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\310\250\0\0\310\250\0\0\5\0\0\0\0\20\0\0\1\0\0\0\310\250\0\0\310\270\0\0\310\270\0\0\34\3\0\0\330\4\0\0\6\0\0\0\0\20\0\0\2\0\0\0\334\250\0\0\334\270\0\0\334\270\0\0\320\0\0\0\320\0\0\0\6\0\0\0\4\0\0\0Q\345td\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\7\0\0\0\4\0\0\0\305\0\0\0\306\0\0\0i\0\0\0\23\0\0\0{\0\0\0\220\0\0\0\0\0\0\0c\0\0\0l\0\0\0\243\0\0\0~\0\0\0\0\0\0\0\234\0\0\0Z\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\254\0\0\0\212\0\0\0\247\0\0\0\r\0\0\0\0\0\0\0X\0\0\0\0\0\0\0\241\0\0\0\206\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\217\0\0\0\0\0\0\0\263\0\0\0\20\0\0\0\200\0\0\0S\0\0\0009\0\0\0[\0\0\0\0\0\0\0\262\0\0\0U\0\0\0\231\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\270\0\0\0\0\0\0\0\304\0\0\0\235\0\0\0\0\0\0\0\0\0\0\0\305\0\0\0\0\0\0\0\0\0\0\0\257\0\0\0\0\0\0\0\223\0\0\0d\0\0\0t\0\0\0\0\0\0\0n\0\0\0\246\0\0\0\0\0\0\0V\0\0\0\0\0\0\0\267\0\0\0\271\0\0\0z\0\0\0\301\0\0\0\27...     Line 232: write(5, "      8643\n", 11)            = 11     Line 233: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 234: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 235: ioctl(5, SNDCTL_TMR_START or TCSETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 236: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 237: read(5, "", 1)                          = 0     Line 238: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 239: ioctl(5, SNDCTL_TMR_START or TCSETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 240: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B115200 -opost -isig -icanon -echo ...}) = 0     Line 242: write(5, "      8643\n", 11)            = 11     Line 243: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 244: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 245: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 246: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 247: read(5, "", 1)                          = 0     Line 248: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 249: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 250: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 252: write(5, "      8643\n", 11)            = 11     Line 253: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 254: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 255: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 256: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 257: read(5, "", 1)                          = 0     Line 258: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 259: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 260: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 262: read(5, "      8612\n", 11)             = 11     Line 264: write(5, "      8643\n", 11)            = 11     Line 265: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 266: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 267: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 268: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 269: read(5, "", 1)                          = 0     Line 270: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 271: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 272: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 274: write(5, "      8643\n", 11)            = 11     Line 276: write(5, "      8643\n", 11)            = 11     Line 277: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 278: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 279: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 280: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 281: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 282: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 283: ioctl(5, SNDCTL_TMR_START or TCSETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 284: ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, {B9600 -opost -isig -icanon -echo ...}) = 0     Line 297: write(5, "ddd", 3)                      = 3     Line 305: write(5, "fff", 3)        But I'm not sure about this line :                Line 112: read(5, "#\n#Tue Jan 14 12:28:06 GMT+01:00 2014\ncurrencyCode=440\nlogFileName=dbg.log\nport=4462\ncommunicationForward=true\nterminalLanguage=4\ntermInterfaces=\ndelLogDaysOld=0\nStopBits=1\nParity=0\nmessagesFileName=language.ini\nDataBits=8\ncomPort=/dev/ttyS0\nInfoInReceiptSlip=1\ntermDataEncoding=1\nBaudRate=9600\nDebugRX=true", 8192) = 311      This info is in configuration file. I dont write this info to com port. What is that?


title: `sort` disregards question mark

text: I need to sort a file based on names in the first column. Some of the names end in a question mark. `sort` persistently ignores this question mark during sorting:               sort -k 1 -t , <<TEST     a?,1     a,2     b?,2     b,1     TEST                    a?,1     a,2     b,1     b?,2      I don’t really care about how `sort` orders the question mark, if it only did it _consistently_. But it doesn’t, it seems to consider the second column instead, _even_ if I tell `sort` explicitly only to use the first column as key. Version info:               $ sort --version     sort (GNU coreutils) 8.22     Packaged by Gentoo (8.22 (p1.0))      Incidentally, on OS X 10.9 (where `sort` identifies itself as “sort (GNU coreutils) 5.93”), the above works as expected for me.


title: What's with `-` in filename affecting sorting order depending on platform?

text: I just checked if contents of directory on my cygwin/Win7 development system, and test embedded platform running Linux+Busybox are the same. Simple, `cat * | md5sum` on both (RXVT/Bash on Cygwin, serial console on Busybox/Bash), compare. And... mismatch. So I went manually file-by-file, doing `md5sum *` and... Cygwin:                 c69a7926998066fcb79aad3e2fc0c33f *blankpack       5866f29a5bc74f741bcc1074c883abaa *cleanup.sh       d4923d7df2540e279664b0633784f1c4 *clean-www.sh       c44ab61b62af040ee55a3e4ddc271299 *d      Linux:                 c69a7926998066fcb79aad3e2fc0c33f *blankpack       d4923d7df2540e279664b0633784f1c4 *clean-www.sh       5866f29a5bc74f741bcc1074c883abaa *cleanup.sh       c44ab61b62af040ee55a3e4ddc271299 *d      Somehow the two cleanup scripts switched places. The same happens with `ls`, `echo *` etc. Is this some bug? Some dependency on the underlying OS? Which of the two orders is the "correct one"(if any)?


title: Reply on same interface as incoming?

text: I have a system with two interfaces. Both interfaces are connected to the internet. One of them is set as the default route; a side effect of this is that if a packet comes in on the non-default-route interface, the reply is sent back through the default route interface. Is there a way to use iptables (or something else) to track the connection and send the reply back through the interface it came from?


title: I had a folder full of files, then I used "sudo mount" to mount a Windows samba share. Where did the files go?

text: I'm using a raspberry pi. I didn't think mounting a samba share to a folder full of files would do anything - I thought it would copy the files to the samba share. Now the files are gone from this folder, but the pi's drive is still full. Where did the files go when I mounted the samba share to the folder?


title: accessing files hidden by mounted drive

text: > **Possible Duplicate:**   >  Access to original contents of mount point I have a directory `d` containing some file `f` and I mount a drive on directory `d`. Is there a way of accessing file `f` without unmounting?


title: Oracle ASM disk group list

text: We have Oracle ASM running under LVM and now I want to expand one of ASM disk group size, but I don't know which LVM filesystem is associated with specific ASM disk group. Is there a way to find out how many raw disk or `LVM` disk associated with ASM disk group? > disk group > > An Oracle ASM disk group is a collection of disks that Oracle ASM manages as > a unit. Within a disk group, Oracle ASM exposes a file system interface for > Oracle Database files. The content of files that are stored in a disk group > are evenly distributed, or striped, to eliminate hot spots and to provide > uniform performance across the disks. Oracle ASM files may also be > optionally mirrored within a disk group. The performance of disks in a disk > group is comparable to the performance of raw devices. ### EDIT #1 following are my disk group in ASM now `EXDATA` running out of space `99% used`. I have enough space in LVM so i am planing to expend LVM disk but i don't know which LVM volume i should expend because there are many LVM disk/filesystem showing in `lvdisplay` command.               [root@devserver ~]# /etc/init.d/oracleasm listdisks     EXDATA     EXLOG     STDATA     STLOG     PXDATA     PXLOG     OCR     XDDATA     XDLOG      Question: How to find which `LVM volume` associated with `EXDATA` (asm)? so i can run `lvextend` on LVM volume and increase the size of EXDATA


title: Activating WiFi in Fedora

text: I am using a Fedora 13 OS and i see that in the network connections the WiFi thing has been disabled. Generally when there is a WiFi connection around it would show in the Wireless networks option, but it is not showing for me. What to do, in order to keep the WiFi mode always active. **ADDED** I have tried the following               iwlist wlan0 power      It says the mode is off. `ifconfig wlan0` gives me the following output: > wlan0 Link encap:Ethernet HWaddr 00:19:7D3:0C:FD   >  UP BROADCAST MULTICAST MTU:1500 Metric:1   >  RX packets:0 errors:0 dropped:0 overruns:0 frame:0   >  TX packets:0 errors:0 dropped:0 overruns:0 carrier:0   >  collisions:0 txqueuelen:1000   >  RX bytes:0 (0.0 b) TX bytes:0 (0.0 b) `iwconfig` has the following: > wlan0 IEEE 802.11bg Mode:Managed Access Point: Not-Associated   >  Tx-Power=20 dBm   >  Retry long limit:7 RTS thr:off Fragment thr:off   >  Power Management:off


title: Connect a keyboard / IR controller to a command line program running in a screen

text: I'm trying to have my Raspberry Pi function as a GUIless music player. I've got Arch Linux installed, and use it through ssh. I've got also an IR receiver dongle, and I'm planning to use it to control the music volume, skip to the next song, play a random song etc. The IR dongle identifies as a keyboard, and writes to /dev/input/event0. At first I tried to make it work with LIRC, but apparently IR dongles that pretend that they are keyboards don't function well with LIRC. My question is that now that I've got some keyboard-like input from my IR receiver, how could I pipe that to the program? Currently I'm using cmus in screen. If there is some kind of general advice how to make my setup work, I'll happily hear that. If not, at least I'd like to get some idea how to connect the IR-receiver-keyboard to a program running in screen. Edit: How stupid of me, why didn't I think of simply catting it in. However, there's a bunch of problems: First of all, `cat /dev/input/event0` just outputs mumble jumble (looks like this, in UTF-8 terminal: �SS�xO��SS�xj��SS�x��SS�CO��SS�Cj��SS�C. One keypress might output half a row of this, and the longer you press, the longer the output.). It certainly responds every time I hit a button of my remote, but I'm not sure what encoding the bytes are in, are they just scancodes or what. Secondly, I still want to control it from ssh, so I need input multiplexer. Third, when I type the following: `cat /dev/input/event0 | screen -rd` or `cat /dev/input/event0 | screen cmus` it complains:               Must be connected to a terminal.


title: How do I `avconv` every m4a in a dir to mp3s?

text: So I'm trying to convert lots of m4as to mp3s, and I think the best way to do that is using `avconv`. The problem is, I can't seem to find any solid examples on how to use `avconv`. Looking at the man page, it has a ridiculous amount of flags/options, and I can't make sense of it. How can I batch convert with `avconv`?


title: Installation location of python modules?

text: How does one get python modules working on a local machine? I followed the doc here: https://docs.python.org/2/install/ to no avail. I tried putting a known working module in the following locations ( `/usr/local/lib/pythonX.Y/site-packages` and `/usr/local/lib/python2.7/site- packages/` ) and an `import` in python does not work. Is there a cache I have to rebuild or something? My Python path: `['', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist- packages/PILcompat', '/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/pymodules/python2.7', '/usr/lib/python2.7/dist-packages/ubuntu-sso- client', '/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode']`


title: Can't start programs in Cygwin

text: I'm trying to start programs in Cygwin, which I want to run over ssh from my Fedora 20 laptop, I'm trying to run the programs within Cygwin not ssh and they don't run. The system is Windows 7 Ultimate with Cygwin installed, not in the default directory, cygwin is on a different drive: N:\cygwin, could this be the cause?. Cygwin X Server is running. Here are the programs I have tried to run from the cygwin command line:   1. Anjuta. The program sometimes displays the window with the logo but then nothing. The program itself doesn't start. There is no error.   2. Monodevelop. The program started when running an Administartor account, but I couldn't create a new project. Under normal user account, which I normally use, it doesn't run. It gives this error: Error: did not find one of the files in sources//usr/lib/monodoc/sources/gd2i node classlib-taglib-sharp is not defined on the documentation map node classlib-webkit is not defined on the documentation map   3. Gedit. Program doesn't start. No error.   4. I haven't tried to run other programs but my guess is they don't work. **I'm a newebie, so I'm a bit lost, how can I fix this?** EDIT: I can run xclock.


title: Process substitution with input redirection

text: I am trying to understand input redirection in combination with process substituation. I am using `bash` 3 An example with `tr` is the following               $ tr "o" "a" <(echo "Foo")     tr: extra operand `/dev/fd/63'     Try `tr --help' for more information.      I think I understand why this does not work. The process substitution `<( )` creates a file descriptor, where `tr` only reads from standard input. How can I make it work with proper redirection? I know that I could simply use pipes:               $ echo "Foo" | tr "o" "a"     Faa      However, I am trying to get a better understanding. I tried some thing with the help of `man bash`, by using `<&`, but I don't really know what I am doing. How can I use process substitution properly using `tr`?


title: emacs wont let me use a different background color

text: I've tried different themes in emacs (on mac with xterm set to 256) and everything works great except it's ignoring the theme's background color. Even if I add (set-background-color "red") for example to my .emacs file, it simply ignores this and uses the default terminal background of OS X.


title: Apache Tomcat not working

text: I am a Linux beginner and have CentOS 6.4 installed on VMware. Recently installed Java SE8 and Apache Tomcat server but I cant't connect to the server by using `localhost:8080' browser says Unable to Connect. I have also tried changing the connector port in the tomcat server config but still unable to connect. **etc/profile**               PATH=/usr/local/jdk1.8.0/bin:$PATH     JRE_HOME=/usr/local/jdk1.8.0/jre/bin     CATALINA_HOME=/media/new/softwares/Tomcat/apache-tomcat-8.0.5/          export PATH     export JRE_HOME     export CATALINA_HOME      **host file**               127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4     ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6      **terminal on starting Tomcat**               Using CATALINA_BASE:   /media/new/softwares/Tomcat/apache-tomcat-8.0.5     Using CATALINA_HOME:   /media/new/softwares/Tomcat/apache-tomcat-8.0.5     Using CATALINA_TMPDIR: /media/new/softwares/Tomcat/apache-tomcat-8.0.5/temp     Using JRE_HOME:        /usr/local/jdk1.8.0/jre/bin     Using CLASSPATH:       /media/new/softwares/Tomcat/apache-tomcat 8.0.5/bin/bootstrap.jar:/media/new/softwares/Tomcat/apache-tomcat-8.0.5/bin/tomcat-juli.jar     Tomcat started.      **tomcat's log**               /media/new/softwares/Tomcat/apache-tomcat-8.0.5/bin/catalina.sh: line 399: /usr/local/jdk1.8.0/jre/bin/bin/java: No such file or directory


title: Mobile Broadband modem in chromium os

text: I'd like to use my internet-stick (T-mobile web'n'walk-Stick IV) in Chromium OS. But in Chromium OS isn't any option to connect it. What can I do? `chronos@localhost / $ modem status Modem /org/freedesktop/ModemManager1/Modem/0: GetStatus: state: 3 Properties: Sim: /org/freedesktop/ModemManager1/SIM/0 ModemCapabilities: 4 CurrentCapabilities: 4 MaxBearers: 1 MaxActiveBearers: 1 Manufacturer: huawei Model: E176 Revision: 11.104.14.01.55 DeviceIdentifier: ad6c2116bb9b15623bb5e74de0dbf65b915ef170 Device: /sys/devices/pci0000:00/0000:00:1d.7/usb1/1-6 Drivers: option1 Plugin: Huawei PrimaryPort: ttyUSB1 EquipmentIdentifier: 355851023696989 UnlockRequired: 1 UnlockRetries: 3, 3, 10, 10 State: 3 StateFailedReason: 0 AccessTechnologies: 0 SignalQuality: 0, false PowerState: 3 SupportedModes: 6 AllowedModes: 6 PreferredMode: 0 SupportedBands: 0 Bands: 0 3GPP: Imei: 355851023696989 RegistrationState: 4 OperatorCode: OperatorName: EnabledFacilityLocks: 0 CDMA: SIM /org/freedesktop/ModemManager1/SIM/0: SimIdentifier: 89490200000608324351 Imsi: 262015844047721 OperatorIdentifier: 26201 OperatorName: T-Mobile D chronos@localhost / $ ` ` chronos@localhost / $ modem connect successfully connected the modem chronos@localhost / $ modem activate error: modem has no CDMA capabilities `


title: Where does the kernel ring buffer sit compared to rsyslog?

text: Is `rsyslog` just an abstraction layer on top of the kernel ring buffer? Or is the kernel ring buffer its own entity and `rsyslog`s interaction is like that of any other "application"?


title: Cloning/Splitting a serial port (COM) port in Ubuntu

text: Everything is working with my serial port. I have connected my FTDI converter into my computer, set my COM port...   `ln -s /dev/ttyUSB0 ~/wine/dosdevices/COM1` But now I would like to "clone" this port. I am using wine to run u-center a GPS visualizer and I have a Linux computer running Ubuntu   Could anyone help?


title: Use keyboard-interactive authentication when piping ssh output to other command

text: I'd like to pipe the output of ssh to a different command. For example:               ssh myserver cat remote-file | diff local-file -      The problem is that myserver asks for a password, but I can't enter it. (For some reason, public-key authentication is not available on the server. I can't change this.) I get the "Password:" prompt, but the keys I type are echoed, and not passed to ssh. How can I make ssh get the password? Note I'm not trying to pipe the password into ssh. I'm trying to pipe the output of ssh, and enter the password as usual. In case it matters, I'm using bash on OS X 10.7 (Lion), and the standard Terminal. I have no aliases set up that could cause this. I've seen the same problem different (Linux) systems, so I believe it's not specific to my setup.


I am trying to upgrade apache 2.2.15 to 2.2.27. While running config.nice taken from apache2.2.15/build I am getting following error:               checking whether the C compiler works... no     configure: error: in `/home/vkuser/httpd-2.2.27/srclib/apr':     configure: error: C compiler cannot create executables      I have tried to search online but no luck. I have also tested out c compiler by running a small test.c script and it runs fine. There were few solution given online like installing 'kernel-devel' package but it did not resolve issue. How can I get this to work? Following is the config.log generated:                   This file contains any messages produced by compilers while         running configure, to aid debugging if configure makes a mistake.              It was created by configure, which was         generated by GNU Autoconf 2.67.  Invocation command line was                $ ./configure --prefix=/opt/myapp/apache2.2 --with-mpm=worker --enable-static-support --enable-ssl=static --enable-modules=most --disable-authndbd --disable-authn-dbm --disable-dbd --enable-static-logresolve --enable-static-rotatelogs --enable-proxy=static --enable-proxyconnect=static --enable-proxy-ftp=static --enable-proxy-http=static --enable-rewrite=static --enable-so=static --with-ssl=/opt/myapp/apache2.2/openssl --host=x86_32-unknown-linux-gnu host_alias=x86_32-unknown-linux-gnu CFLAGS=-m32 LDFLAGS=-m32 --with-included-apr              ## --------- ##         ## Platform. ##         ## --------- ##              hostname = dmcpq-000         uname -m = x86_64         uname -r = 2.6.18-348.12.1.el5         uname -s = Linux         uname -v = #1 SMP Mon Jul 1 17:54:12 EDT 2013              /usr/bin/uname -p = unknown         /bin/uname -X     = unknown              /bin/arch              = x86_64         /usr/bin/arch -k       = unknown         /usr/convex/getsysinfo = unknown         /usr/bin/hostinfo      = unknown         /bin/machine           = unknown         /usr/bin/oslevel       = unknown         /bin/universe          = unknown              PATH: /opt/myapp/Entrust/GetAccess/Runtime/Apache22/bin         PATH: /usr/kerberos/sbin         PATH: /usr/kerberos/bin         PATH: /usr/local/sbin         PATH: /usr/local/bin         PATH: /sbin         PATH: /bin         PATH: /usr/sbin         PATH: /usr/bin         PATH: /root/bin                   ## ----------- ##         ## Core tests. ##         ## ----------- ##              configure:2793: checking for chosen layout         configure:2795: result: Apache         configure:3598: checking for working mkdir -p         configure:3614: result: yes         configure:3629: checking build system type         configure:3643: result: x86_64-unknown-linux-gnu         configure:3663: checking host system type         configure:3676: result: x86_32-unknown-linux-gnu         configure:3696: checking target system type         configure:3709: result: x86_32-unknown-linux-gnu              ## ---------------- ##         ## Cache variables. ##         ## ---------------- ##              ac_cv_build=x86_64-unknown-linux-gnu         ac_cv_env_CC_set=         ac_cv_env_CC_value=         ac_cv_env_CFLAGS_set=set         ac_cv_env_CFLAGS_value=-m32         ac_cv_env_CPPFLAGS_set=         ac_cv_env_CPPFLAGS_value=         ac_cv_env_CPP_set=         ac_cv_env_CPP_value=         ac_cv_env_LDFLAGS_set=set         ac_cv_env_LDFLAGS_value=-m32         ac_cv_env_LIBS_set=         ac_cv_env_LIBS_value=         ac_cv_env_build_alias_set=         ac_cv_env_build_alias_value=         ac_cv_env_host_alias_set=set         ac_cv_env_host_alias_value=x86_32-unknown-linux-gnu         ac_cv_env_target_alias_set=         ac_cv_env_target_alias_value=         ac_cv_host=x86_32-unknown-linux-gnu         ac_cv_mkdir_p=yes         ac_cv_target=x86_32-unknown-linux-gnu              ## ----------------- ##         ## Output variables. ##         ## ----------------- ##              APACHECTL_ULIMIT=''         APR_BINDIR=''         APR_CONFIG=''         APR_INCLUDEDIR=''         APR_VERSION=''         APU_BINDIR=''         APU_CONFIG=''         APU_INCLUDEDIR=''         APU_VERSION=''         AP_BUILD_SRCLIB_DIRS=''         AP_CLEAN_SRCLIB_DIRS=''         AP_LIBS=''         AWK=''         BUILTIN_LIBS=''         CC=''         CFLAGS='-m32'         CORE_IMPLIB=''         CORE_IMPLIB_FILE=''         CPP=''         CPPFLAGS=''         CRYPT_LIBS=''         CXX=''         CXXFLAGS=''         DEFS=''         DSO_MODULES=''         ECHO_C=''         ECHO_N='-n'         ECHO_T=''         EGREP=''         EXEEXT=''         EXTRA_CFLAGS=''         EXTRA_CPPFLAGS=''         EXTRA_CXXFLAGS=''         EXTRA_INCLUDES=''         EXTRA_LDFLAGS=''         EXTRA_LIBS=''         GREP=''         HTTPD_LDFLAGS=''         HTTPD_VERSION=''         INCLUDES=''         INSTALL=''         INSTALL_DSO=''         INSTALL_PROG_FLAGS=''         LDFLAGS='-m32'         LIBOBJS=''         LIBS=''         LIBTOOL=''         LN_S=''         LTCFLAGS=''         LTFLAGS=''         LTLIBOBJS=''         LT_LDFLAGS=''         LYNX_PATH=''         MKDEP=''         MKINSTALLDIRS=''         MK_IMPLIB=''         MODULE_CLEANDIRS=''         MODULE_DIRS=''         MOD_ACTIONS_LDADD=''         MOD_ALIAS_LDADD=''         MOD_ASIS_LDADD=''         MOD_AUTHNZ_LDAP_LDADD=''         MOD_AUTHN_ALIAS_LDADD=''         MOD_AUTHN_ANON_LDADD=''         MOD_AUTHN_DBD_LDADD=''         MOD_AUTHN_DBM_LDADD=''         MOD_AUTHN_DEFAULT_LDADD=''         MOD_AUTHN_FILE_LDADD=''         MOD_AUTHZ_DBM_LDADD=''         MOD_AUTHZ_DEFAULT_LDADD=''         MOD_AUTHZ_GROUPFILE_LDADD=''         MOD_AUTHZ_HOST_LDADD=''         MOD_AUTHZ_OWNER_LDADD=''         MOD_AUTHZ_USER_LDADD=''         MOD_AUTH_BASIC_LDADD=''         MOD_AUTH_DIGEST_LDADD=''         MOD_AUTOINDEX_LDADD=''         MOD_BUCKETEER_LDADD=''         MOD_CACHE_LDADD=''         MOD_CASE_FILTER_IN_LDADD=''         MOD_CASE_FILTER_LDADD=''         MOD_CERN_META_LDADD=''         MOD_CGID_LDADD=''         MOD_CGI_LDADD=''         MOD_CHARSET_LITE_LDADD=''         MOD_DAV_FS_LDADD=''         MOD_DAV_LDADD=''         MOD_DAV_LOCK_LDADD=''         MOD_DBD_LDADD=''         MOD_DEFLATE_LDADD=''         MOD_DIR_LDADD=''         MOD_DISK_CACHE_LDADD=''         MOD_DUMPIO_LDADD=''         MOD_ECHO_LDADD=''         MOD_ENV_LDADD=''         MOD_EXAMPLE_LDADD=''         MOD_EXPIRES_LDADD=''         MOD_EXT_FILTER_LDADD=''         MOD_FILE_CACHE_LDADD=''         MOD_FILTER_LDADD=''         MOD_HEADERS_LDADD=''         MOD_HTTP_LDADD=''         MOD_IDENT_LDADD=''         MOD_IMAGEMAP_LDADD=''         MOD_INCLUDE_LDADD=''         MOD_INFO_LDADD=''         MOD_ISAPI_LDADD=''         MOD_LDAP_LDADD=''         MOD_LOGIO_LDADD=''         MOD_LOG_CONFIG_LDADD=''         MOD_LOG_FORENSIC_LDADD=''         MOD_MEM_CACHE_LDADD=''         MOD_MIME_LDADD=''         MOD_MIME_MAGIC_LDADD=''         MOD_NEGOTIATION_LDADD=''         MOD_OPTIONAL_FN_EXPORT_LDADD=''         MOD_OPTIONAL_FN_IMPORT_LDADD=''         MOD_OPTIONAL_HOOK_EXPORT_LDADD=''         MOD_OPTIONAL_HOOK_IMPORT_LDADD=''         MOD_PROXY_AJP_LDADD=''         MOD_PROXY_BALANCER_LDADD=''         MOD_PROXY_CONNECT_LDADD=''         MOD_PROXY_FTP_LDADD=''         MOD_PROXY_HTTP_LDADD=''         MOD_PROXY_LDADD=''         MOD_PROXY_SCGI_LDADD=''         MOD_REQTIMEOUT_LDADD=''         MOD_REWRITE_LDADD=''         MOD_SETENVIF_LDADD=''         MOD_SO_LDADD=''         MOD_SPELING_LDADD=''         MOD_SSL_LDADD=''         MOD_STATUS_LDADD=''         MOD_SUBSTITUTE_LDADD=''         MOD_SUEXEC_LDADD=''         MOD_UNIQUE_ID_LDADD=''         MOD_USERDIR_LDADD=''         MOD_USERTRACK_LDADD=''         MOD_VERSION_LDADD=''         MOD_VHOST_ALIAS_LDADD=''         MPM_LIB=''         MPM_NAME=''         MPM_SUBDIR_NAME=''         NONPORTABLE_SUPPORT=''         NOTEST_CFLAGS=''         NOTEST_CPPFLAGS=''         NOTEST_CXXFLAGS=''         NOTEST_LDFLAGS=''         NOTEST_LIBS=''         OBJEXT=''         OS=''         OS_DIR=''         OS_SPECIFIC_VARS=''         PACKAGE_BUGREPORT=''         PACKAGE_NAME=''         PACKAGE_STRING=''         PACKAGE_TARNAME=''         PACKAGE_URL=''         PACKAGE_VERSION=''         PATH_SEPARATOR=':'         PCRE_CONFIG=''         PICFLAGS=''         PILDFLAGS=''         PKGCONFIG=''         PORT=''         POST_SHARED_CMDS=''         PRE_SHARED_CMDS=''         RANLIB=''         RM=''         RSYNC=''         SHELL='/bin/sh'         SHLIBPATH_VAR=''         SHLTCFLAGS=''         SH_LDFLAGS=''         SH_LIBS=''         SH_LIBTOOL=''         SSLPORT=''         SSL_LIBS=''         UTIL_LDFLAGS=''         ab_LTFLAGS=''         abs_srcdir=''         ac_ct_CC=''         ap_make_delimiter=''         ap_make_include=''         bindir='${exec_prefix}/bin'         build='x86_64-unknown-linux-gnu'         build_alias=''         build_cpu='x86_64'         build_os='linux-gnu'         build_vendor='unknown'         cgidir='${datadir}/cgi-bin'         checkgid_LTFLAGS=''         datadir='${prefix}'         datarootdir='${prefix}/share'         docdir='${datarootdir}/doc/${PACKAGE}'         dvidir='${docdir}'         errordir='${datadir}/error'         exec_prefix='${prefix}'         exp_bindir='/opt/myapp/apache2.2/bin'         exp_cgidir='/opt/myapp/apache2.2/cgi-bin'         exp_datadir='/opt/myapp/apache2.2'         exp_errordir='/opt/myapp/apache2.2/error'         exp_exec_prefix='/opt/myapp/apache2.2'         exp_htdocsdir='/opt/myapp/apache2.2/htdocs'         exp_iconsdir='/opt/myapp/apache2.2/icons'         exp_includedir='/opt/myapp/apache2.2/include'         exp_installbuilddir='/opt/myapp/apache2.2/build'         exp_libdir='/opt/myapp/apache2.2/lib'         exp_libexecdir='/opt/myapp/apache2.2/modules'         exp_localstatedir='/opt/myapp/apache2.2'         exp_logfiledir='/opt/myapp/apache2.2/logs'         exp_mandir='/opt/myapp/apache2.2/man'         exp_manualdir='/opt/myapp/apache2.2/manual'         exp_proxycachedir='/opt/myapp/apache2.2/proxy'         exp_runtimedir='/opt/myapp/apache2.2/logs'         exp_sbindir='/opt/myapp/apache2.2/bin'         exp_sysconfdir='/opt/myapp/apache2.2/conf'         host='x86_32-unknown-linux-gnu'         host_alias='x86_32-unknown-linux-gnu'         host_cpu='x86_32'         host_os='linux-gnu'         host_vendor='unknown'         htcacheclean_LTFLAGS=''         htdbm_LTFLAGS=''         htdigest_LTFLAGS=''         htdocsdir='${datadir}/htdocs'         htmldir='${docdir}'         htpasswd_LTFLAGS=''         httxt2dbm_LTFLAGS=''         iconsdir='${datadir}/icons'         includedir='${prefix}/include'         infodir='${datarootdir}/info'         installbuilddir='${datadir}/build'         libdir='${exec_prefix}/lib'         libexecdir='${exec_prefix}/modules'         localedir='${datarootdir}/locale'         localstatedir='${prefix}'         logfiledir='${localstatedir}/logs'         logresolve_LTFLAGS=''         mandir='${prefix}/man'         manualdir='${datadir}/manual'         nonssl_listen_stmt_1=''         nonssl_listen_stmt_2=''         oldincludedir='/usr/include'         other_targets=''         pdfdir='${docdir}'         perlbin=''         prefix='/opt/myapp/apache2.2'         progname=''         program_transform_name='s,x,x,'         proxycachedir='${localstatedir}/proxy'         psdir='${docdir}'         rel_bindir='bin'         rel_cgidir='cgi-bin'         rel_datadir=''         rel_errordir='error'         rel_exec_prefix=''         rel_htdocsdir='htdocs'         rel_iconsdir='icons'         rel_includedir='include'         rel_installbuilddir='build'         rel_libdir='lib'         rel_libexecdir='modules'         rel_localstatedir=''         rel_logfiledir='logs'         rel_mandir='man'         rel_manualdir='manual'         rel_proxycachedir='proxy'         rel_runtimedir='logs'         rel_sbindir='bin'         rel_sysconfdir='conf'         rotatelogs_LTFLAGS=''         runtimedir='${localstatedir}/logs'         sbindir='${exec_prefix}/bin'         shared_build=''         sharedstatedir='${prefix}/com'         sysconfdir='${prefix}/conf'         target='x86_32-unknown-linux-gnu'         target_alias=''         target_cpu='x86_32'         target_os='linux-gnu'         target_vendor='unknown'              configure: exit 1


title: Will suspension or hibernation of OS suspend running programs?

text: I am running a program in my terminal. BUt I need to suspend or hibernate the OS (Ubuntu 12.04) for a while. Do I have to Ctrl-Z my running program before doing that? Or will suspension or hibernation of the OS also suspend the running program and allow resuming the program after the OS wakes up? Thanks!


title: Questions about kernel releases

text: Right now there are about 7 (or more) kernels maintained by the Linux Foundation. I was wondering if you could clarify my doubts and answer my questions:   1. Isn't the next kernel's release maintaining everything that was included in previous release?   2. If not, what's the purpose of naming a kernel with higher number, if it's not having the content of the previous one (like in apps)?   3. Why there has to be so many kernels maintained at the same time, wouldn't e.g. 2 LTS and one or two regular ones be enough? I'm just simply not following the philosophy of the releases.


title: Sendmail with TLS support changes FROM: address

text: I have multiple domains on one server and when sending email to server, which supports TLS, server changes FROM field to default domain ($j). What should i do (in .mc level please) to remain primary domain (all domains are qualified)?               Jul 14 10:59:16 server sendmail[19537]: p6E7xGt3019537: from=user@domain-a.com, size=491, class=0, nrcpts=1, msgid=<1310630356.19535@domain-a.com>, relay=loggedinuser@localhost     Jul 14 10:59:17 server sendmail[19538]: STARTTLS=server, relay=localhost.localdomain [127.0.0.1], version=TLSv1/SSLv3, verify=NOT, cipher=DHE-RSA-AES256-SHA, bits=256/256     Jul 14 10:59:17 server sendmail[19537]: STARTTLS=client, relay=[127.0.0.1], version=TLSv1/SSLv3, verify=FAIL, cipher=DHE-RSA-AES256-SHA, bits=256/256     Jul 14 10:59:17 server sendmail[19538]: p6E7xG06019538: from=<user@domain-b.com>, size=607, class=0, nrcpts=1, msgid=<1310630356.19535@domain-a.com>, proto=ESMTP, daemon=MTA,relay=localhost.localdomain [127.0.0.1]     Jul 14 10:59:18 server sendmail[19537]: p6E7xGt3019537: to=recepient@domain-c.com, ctladdr=user@domain-a.com (1005/100), delay=00:00:02, xdelay=00:00:02, mailer=relay, pri=30491, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (p6E7xG06019538 Message accepted for delivery)     Jul 14 10:59:18 server sendmail[19540]: STARTTLS=client, relay=smtp3.domain-c.com., version=TLSv1/SSLv3, verify=FAIL, cipher=DHE-RSA-AES256-SHA, bits=256/256     Jul 14 10:59:18 server sendmail[19540]: p6E7xG06019538: to=<recepient@domain-c.com>, ctladdr=<user@domain-b.com> (1005/100), delay=00:00:01, xdelay=00:00:00, mailer=esmtp, pri=120607, relay=smtp3.domain-c.com. [93.40.95.67], dsn=2.0.0, stat=Sent (Ok: queued as 2117414003)


title: How to skip file in sed if it contains regex?

text: I currently use the following simplified command to _remove trailing whitespace_ and _add a newline at end of file_ where needed:               find . -type f -exec sed -i -e 's/[ \t]\+\(\r\?\)$/\1/;$a\' {} \+      As you'll quickly see, this has two problems: It will change _binary files_ and it will add a newline to the end of files with _␍␊ line separators_. These modifications are easy to undo or skip when committing in `git gui` or the like, but I'd like to minimize* the amount of reverting. To that end: **Is there a way to skip the _whole_ file if _any_ line matches a regex in `sed`?** * I'm aware that there might be binary files without ␀ characters, and there could be files with deliberately mixed newlines or ␀s. But I'm looking for the solution which requires the minimal human intervention. I _could_ conceivably list all the file extensions that I'd like to operate on, but it would be a very long list which would have to be constantly reviewed, and because of name clashes it would still be possible that binary files slip through. Complicated workaround:               while IFS= read -r -d '' -u 9     do         if [[ "$(file -bs --mime-type -- "$REPLY")" = text/* ]]         then             sed -i -e 's/[ \t]\+\(\r\?\)$/\1/;$a\' -- "$REPLY"         else             echo "Skipping $REPLY" >&2         fi     done 9< <(find . -type f -print0)


title: bash using a file name as input

text: Im pretty stupid when in comes to bash and I was hoping someone could help me. I would like to take the output of               hg resolve -l      which is in the format               R somefile/filename     U somefile/filename     R somefile/filename     U somefile/filename      and be able to use the first line that starts with a 'U' as an argument, so i could do things like               open -t <first U file>      and               hg resolve -m <first U file>      it would be great it someone could give me some pointers about the best way to do this! Thanks EDIT: solution from answers below, a simple script. Thanks guys!               #!/bin/bash          # Script that gets the first file from hg resolve | grep U and passes to default text editor          first_u_file=$(hg resolve -l | grep -m1 '^U')     first_u_file=${first_u_file#U }     echo opening \'$first_u_file\'     open -t "$first_u_file"


title: Creating an ext4 partition fails with "invalid blocks count"

text: Environment: - Virtual machine on VMWare ESX 4.0 - OS: fully up to date RHEL 5.8 After adding a new (virtual) disk I want to create an ext4 partition on LVM on this disk. Steps taken so far:               $ sudo /sbin/fdisk /dev/sdb     Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel     Building a new DOS disklabel. Changes will remain in memory only,     until you decide to write them. After that, of course, the previous     content won't be recoverable.               The number of cylinders for this disk is set to 10443.     There is nothing wrong with that, but this is larger than 1024,     and could in certain setups cause problems with:     1) software that runs at boot time (e.g., old versions of LILO)     2) booting and partitioning software from other OSs        (e.g., DOS FDISK, OS/2 FDISK)     Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)          Command (m for help): n     p     Partition number (1-4): 1     First cylinder (1-10443, default 1):     Using default value 1     Last cylinder or +size or +sizeM or +sizeK (1-10443, default 10443):     Using default value 10443          Command (m for help): t     Selected partition 1     Hex code (type L to list codes): 8e     Changed system type of partition 1 to 8e (Linux LVM)          Command (m for help): w     The partition table has been altered!          Calling ioctl() to re-read partition table.     Syncing disks.     $ sudo /usr/sbin/pvcreate /dev/sdb1       Writing physical volume data to disk "/dev/sdb1"       Physical volume "/dev/sdb1" successfully created     $ sudo /usr/sbin/vgcreate VGora /dev/sdb1       /dev/hdc: open failed: No medium found       Volume group "VGora" successfully created     $ sudo /usr/sbin/lvcreate -l "100%FREE" -n oradata VGora       Logical volume "oradata" created      Creating an ext4 partition fails:               $ sudo /sbin/mke2fs -t ext4 /dev/VGora/oradata     mke2fs 1.39 (29-May-2006)     mke2fs: invalid blocks count - /dev/VGora/oradata      More information on the created partition:               $ sudo /usr/sbin/vgdisplay VGora       --- Volume group ---       VG Name               VGora       System ID       Format                lvm2       Metadata Areas        1       Metadata Sequence No  2       VG Access             read/write       VG Status             resizable       MAX LV                0       Cur LV                1       Open LV               0       Max PV                0       Cur PV                1       Act PV                1       VG Size               80.00 GB       PE Size               4.00 MB       Total PE              20479       Alloc PE / Size       20479 / 80.00 GB       Free  PE / Size       0 / 0       VG UUID               ggjERV-sGbG-1nCv-HW61-LJk4-I7cX-Z3Infh          $ sudo /usr/sbin/lvdisplay VGora       --- Logical volume ---       LV Name                /dev/VGora/oradata       VG Name                VGora       LV UUID                nia1PK-7JJ2-jg5T-uN4X-ggYH-R0mS-oqCooY       LV Write Access        read/write       LV Status              available       # open                 0       LV Size                80.00 GB       Current LE             20479       Segments               1       Allocation             inherit       Read ahead sectors     auto       - currently set to     256       Block device           253:4          $ sudo /sbin/fdisk -l /dev/sdb          Disk /dev/sdb: 85.8 GB, 85899345920 bytes     255 heads, 63 sectors/track, 10443 cylinders     Units = cylinders of 16065 * 512 = 8225280 bytes             Device Boot      Start         End      Blocks   Id  System     /dev/sdb1               1       10443    83883366   8e  Linux LVM      I can't find any relevant information on this error and don't know how to resolve this.   * How can I check the block count? and   * How can I correct it to a valid number for ext4?


title: How do I set Zsh autocompletion rules for second argument (of function) to an existing command's rules?

text: I have a custom Zsh function `g`:               function g() {       # Handle arguments [...]     }      Within it, I handle short arguments that execute Git commands. For example:               g ls # Executes git ls-files ...     g g  # Executes git grep ...      I need to be able to set the autocompletion rules to Git's rules for the short arguments but I am unsure of how to do this. For example, I need `g ls <TAB>` to tab-complete the rules for `git ls-files <TAB>` which would give me the arguments for `git ls-files`:               $ g ls --<TAB>     --abbrev                 -- set minimum SHA1 display-length     --cached                 -- show cached files in output     --deleted                -- show deleted files in output     # Etc...      This is not simply setting `g` to autocomplete for `git` since I'm mapping my custom short commands to the Git commands.


title: Migrate a qcow2 image between storage pools

text: I have 2 storage pools.   1. host_images (directory storage pool)   2. remote_images (nfs storage pool) How do I copy qcow images from remote_images to host_images using libvirt APIs? I've tried using the obvious vol-clone, but apparently it doesn't work across storage pools I've tried using vol-download but that takes an obscene amount of time (in the order of 10+mins for 500MB) Am I architecting this wrong? Should I not be trying to use libvirt to control these aspects of automation? I wanted to use libvirt for all aspects of automation so I could be consistent in my tool utilization. But if the tools don't work I cannot continue to use libvirt. I'm also wondering if vol-clone does not work how does KVM perform migration to another host? What tools does it use to migrate if not libvirt?


title: tmux exits immediately after starting

text: I'm trying to start with Tmux but failing to even run it. Immediately after starting it exits. looked like It's the same as this question It happens both without a .tmux.conf and (following some examples) with this .tmux.conf:               set -g default-shell /usr/bin/zsh     set -g status on     set -g history-limit 10000000     set -g prefix C-t     set -g status-bg green     setw -g window-status-current-bg cyan     setw -g window-status-current-attr bold          set -g status-right '#7H | %F %s'          bind-key C-t last-window          setw -g monitor-activity on     set -g visual-activity on      Adding new-session in the beginning of the .tmux.conf as suggested some places doesn't help and this happens when I use tmux new $SHELL also (again suggested to solve this somewhere) using:   * tmux 1.9a   * ubuntu 14.04   * zsh (5.0.2) I'll be glad for help with this. tmux-server.log file output of `tmux -v` command               server started, pid 19654     socket path /tmp/tmux-1000/default     new client 7     loading /home/alon/.tmux.conf     /home/alon/.tmux.conf: new-session     /home/alon/.tmux.conf: set -g default-shell /usr/bin/zsh     /home/alon/.tmux.conf: set -g status on     /home/alon/.tmux.conf: set -g history-limit 10000000     /home/alon/.tmux.conf: set -g prefix C-t     /home/alon/.tmux.conf: set -g status-bg green     /home/alon/.tmux.conf: setw -g window-status-current-bg cyan     /home/alon/.tmux.conf: setw -g window-status-current-attr bold     /home/alon/.tmux.conf:      /home/alon/.tmux.conf: set -g status-right '#7H | %F %s'     /home/alon/.tmux.conf:      /home/alon/.tmux.conf: bind-key C-t last-window     /home/alon/.tmux.conf:      /home/alon/.tmux.conf: setw -g monitor-activity on     /home/alon/.tmux.conf: set -g visual-activity on     cmdq 0x7f75d1784b50: new-session (client -1)     spawn: /usr/bin/zsh --      session 0 created     cmdq 0x7f75d1784b50: set-option -g default-shell /usr/bin/zsh (client -1)     cmdq 0x7f75d1784b50: set-option -g status on (client -1)     cmdq 0x7f75d1784b50: set-option -g history-limit 10000000 (client -1)     cmdq 0x7f75d1784b50: set-option -g prefix C-t (client -1)     cmdq 0x7f75d1784b50: set-option -g status-bg green (client -1)     cmdq 0x7f75d1784b50: set-window-option -g window-status-current-bg cyan (client -1)     cmdq 0x7f75d1784b50: set-window-option -g window-status-current-attr bold (client -1)     cmdq 0x7f75d1784b50: set-option -g status-right "#7H | %F %s" (client -1)     cmdq 0x7f75d1784b50: bind-key C-t last-window (client -1)     cmdq 0x7f75d1784b50: set-window-option -g monitor-activity on (client -1)     cmdq 0x7f75d1784b50: set-option -g visual-activity on (client -1)     got 100 from client 7     got 101 from client 7     got 102 from client 7     got 103 from client 7     got 104 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 105 from client 7     got 106 from client 7     got 200 from client 7     cmdq 0x7f75d176b260: new-session (client 7)     new term: xterm     xterm override: XT      xterm override: Ms ]52;%p1%s;%p2%s     xterm override: Cs ]12;%p1%s     xterm override: Cr ]112     xterm override: Ss [%p1%d q     xterm override: Se [2 q     new key Oo: 0x1021 (KP/)     new key Oj: 0x1022 (KP*)     new key Om: 0x1023 (KP-)     new key Ow: 0x1024 (KP7)     new key Ox: 0x1025 (KP8)     new key Oy: 0x1026 (KP9)     new key Ok: 0x1027 (KP+)     new key Ot: 0x1028 (KP4)     new key Ou: 0x1029 (KP5)     new key Ov: 0x102a (KP6)     new key Oq: 0x102b (KP1)     new key Or: 0x102c (KP2)     new key Os: 0x102d (KP3)     new key OM: 0x102e (KPEnter)     new key Op: 0x102f (KP0)     new key On: 0x1030 (KP.)     new key OA: 0x101d (Up)     new key OB: 0x101e (Down)     new key OC: 0x1020 (Right)     new key OD: 0x101f (Left)     new key [A: 0x101d (Up)     new key [B: 0x101e (Down)     new key [C: 0x1020 (Right)     new key [D: 0x101f (Left)     new key OH: 0x1018 (Home)     new key OF: 0x1019 (End)     new key [H: 0x1018 (Home)     new key [F: 0x1019 (End)     new key Oa: 0x501d (C-Up)     new key Ob: 0x501e (C-Down)     new key Oc: 0x5020 (C-Right)     new key Od: 0x501f (C-Left)     new key [a: 0x901d (S-Up)     new key [b: 0x901e (S-Down)     new key [c: 0x9020 (S-Right)     new key [d: 0x901f (S-Left)     new key [11^: 0x5002 (C-F1)     new key [12^: 0x5003 (C-F2)     new key [13^: 0x5004 (C-F3)     new key [14^: 0x5005 (C-F4)     new key [15^: 0x5006 (C-F5)     new key [17^: 0x5007 (C-F6)     new key [18^: 0x5008 (C-F7)     new key [19^: 0x5009 (C-F8)     new key [20^: 0x500a (C-F9)     new key [21^: 0x500b (C-F10)     new key [23^: 0x500c (C-F11)     new key [24^: 0x500d (C-F12)     new key [25^: 0x500e (C-F13)     new key [26^: 0x500f (C-F14)     new key [28^: 0x5010 (C-F15)     new key [29^: 0x5011 (C-F16)     new key [31^: 0x5012 (C-F17)     new key [32^: 0x5013 (C-F18)     new key [33^: 0x5014 (C-F19)     new key [34^: 0x5015 (C-F20)     new key [2^: 0x5016 (C-IC)     new key [3^: 0x5017 (C-DC)     new key [7^: 0x5018 (C-Home)     new key [8^: 0x5019 (C-End)     new key [6^: 0x501a (C-NPage)     new key [5^: 0x501b (C-PPage)     new key [11$: 0x9002 (S-F1)     new key [12$: 0x9003 (S-F2)     new key [13$: 0x9004 (S-F3)     new key [14$: 0x9005 (S-F4)     new key [15$: 0x9006 (S-F5)     new key [17$: 0x9007 (S-F6)     new key [18$: 0x9008 (S-F7)     new key [19$: 0x9009 (S-F8)     new key [20$: 0x900a (S-F9)     new key [21$: 0x900b (S-F10)     new key [23$: 0x900c (S-F11)     new key [24$: 0x900d (S-F12)     new key [25$: 0x900e (S-F13)     new key [26$: 0x900f (S-F14)     new key [28$: 0x9010 (S-F15)     new key [29$: 0x9011 (S-F16)     new key [31$: 0x9012 (S-F17)     new key [32$: 0x9013 (S-F18)     new key [33$: 0x9014 (S-F19)     new key [34$: 0x9015 (S-F20)     new key [2$: 0x9016 (S-IC)     new key [3$: 0x9017 (S-DC)     new key [7$: 0x9018 (S-Home)     new key [8$: 0x9019 (S-End)     new key [6$: 0x901a (S-NPage)     new key [5$: 0x901b (S-PPage)     new key [11@: 0xd002 (C-S-F1)     new key [12@: 0xd003 (C-S-F2)     new key [13@: 0xd004 (C-S-F3)     new key [14@: 0xd005 (C-S-F4)     new key [15@: 0xd006 (C-S-F5)     new key [17@: 0xd007 (C-S-F6)     new key [18@: 0xd008 (C-S-F7)     new key [19@: 0xd009 (C-S-F8)     new key [20@: 0xd00a (C-S-F9)     new key [21@: 0xd00b (C-S-F10)     new key [23@: 0xd00c (C-S-F11)     new key [24@: 0xd00d (C-S-F12)     new key [25@: 0xd00e (C-S-F13)     new key [26@: 0xd00f (C-S-F14)     new key [28@: 0xd010 (C-S-F15)     new key [29@: 0xd011 (C-S-F16)     new key [31@: 0xd012 (C-S-F17)     new key [32@: 0xd013 (C-S-F18)     new key [33@: 0xd014 (C-S-F19)     new key [34@: 0xd015 (C-S-F20)     new key [2@: 0xd016 (C-S-IC)     new key [3@: 0xd017 (C-S-DC)     new key [7@: 0xd018 (C-S-Home)     new key [8@: 0xd019 (C-S-End)     new key [6@: 0xd01a (C-S-NPage)     new key [5@: 0xd01b (C-S-PPage)     new key [I: 0x1031 ((null))     new key [O: 0x1032 ((null))     new key OP: 0x1002 (F1)     new key OQ: 0x1003 (F2)     new key OR: 0x1004 (F3)     new key OS: 0x1005 (F4)     new key [15~: 0x1006 (F5)     new key [17~: 0x1007 (F6)     new key [18~: 0x1008 (F7)     new key [19~: 0x1009 (F8)     new key [20~: 0x100a (F9)     new key [21~: 0x100b (F10)     new key [23~: 0x100c (F11)     new key [24~: 0x100d (F12)     new key [1;2P: 0x100e (F13)     new key [1;2Q: 0x100f (F14)     new key [1;2R: 0x1010 (F15)     new key [1;2S: 0x1011 (F16)     new key [15;2~: 0x1012 (F17)     new key [17;2~: 0x1013 (F18)     new key [18;2~: 0x1014 (F19)     new key [19;2~: 0x1015 (F20)     new key [2~: 0x1016 (IC)     new key [3~: 0x1017 (DC)     replacing key OH: 0x1018 (Home)     replacing key OF: 0x1019 (End)     new key [6~: 0x101a (NPage)     new key [5~: 0x101b (PPage)     new key [Z: 0x101c (BTab)     replacing key OA: 0x101d (Up)     replacing key OB: 0x101e (Down)     replacing key OD: 0x101f (Left)     replacing key OC: 0x1020 (Right)     new key [3;2~: 0x9017 (S-DC)     new key [3;3~: 0x3017 (M-DC)     new key [3;4~: 0xb017 (M-S-DC)     new key [3;5~: 0x5017 (C-DC)     new key [3;6~: 0xd017 (C-S-DC)     new key [3;7~: 0x7017 (C-M-DC)     new key [1;2B: 0x901e (S-Down)     new key [1;3B: 0x301e (M-Down)     new key [1;4B: 0xb01e (M-S-Down)     new key [1;5B: 0x501e (C-Down)     new key [1;6B: 0xd01e (C-S-Down)     new key [1;7B: 0x701e (C-M-Down)     new key [1;2F: 0x9019 (S-End)     new key [1;3F: 0x3019 (M-End)     new key [1;4F: 0xb019 (M-S-End)     new key [1;5F: 0x5019 (C-End)     new key [1;6F: 0xd019 (C-S-End)     new key [1;7F: 0x7019 (C-M-End)     new key [1;2H: 0x9018 (S-Home)     new key [1;3H: 0x3018 (M-Home)     new key [1;4H: 0xb018 (M-S-Home)     new key [1;5H: 0x5018 (C-Home)     new key [1;6H: 0xd018 (C-S-Home)     new key [1;7H: 0x7018 (C-M-Home)     new key [2;2~: 0x9016 (S-IC)     new key [2;3~: 0x3016 (M-IC)     new key [2;4~: 0xb016 (M-S-IC)     new key [2;5~: 0x5016 (C-IC)     new key [2;6~: 0xd016 (C-S-IC)     new key [2;7~: 0x7016 (C-M-IC)     new key [1;2D: 0x901f (S-Left)     new key [1;3D: 0x301f (M-Left)     new key [1;4D: 0xb01f (M-S-Left)     new key [1;5D: 0x501f (C-Left)     new key [1;6D: 0xd01f (C-S-Left)     new key [1;7D: 0x701f (C-M-Left)     new key [6;2~: 0x901a (S-NPage)     new key [6;3~: 0x301a (M-NPage)     new key [6;4~: 0xb01a (M-S-NPage)     new key [6;5~: 0x501a (C-NPage)     new key [6;6~: 0xd01a (C-S-NPage)     new key [6;7~: 0x701a (C-M-NPage)     new key [5;2~: 0x901b (S-PPage)     new key [5;3~: 0x301b (M-PPage)     new key [5;4~: 0xb01b (M-S-PPage)     new key [5;5~: 0x501b (C-PPage)     new key [5;6~: 0xd01b (C-S-PPage)     new key [5;7~: 0x701b (C-M-PPage)     new key [1;2C: 0x9020 (S-Right)     new key [1;3C: 0x3020 (M-Right)     new key [1;4C: 0xb020 (M-S-Right)     new key [1;5C: 0x5020 (C-Right)     new key [1;6C: 0xd020 (C-S-Right)     new key [1;7C: 0x7020 (C-M-Right)     new key [1;2A: 0x901d (S-Up)     new key [1;3A: 0x301d (M-Up)     new key [1;4A: 0xb01d (M-S-Up)     new key [1;5A: 0x501d (C-Up)     new key [1;6A: 0xd01d (C-S-Up)     new key [1;7A: 0x701d (C-M-Up)     spawn: /usr/bin/zsh --      session 1 created     writing 207 to client 7     got 208 from client 7     keys are 9 ([?62;9;c)     received service class 62     complete key [?62;9;c 0xfff     session 0 destroyed     session 1 destroyed     writing 203 to client 7     got 205 from client 7     writing 204 to client 7     lost client 7


title: Command to retrieve the list of characters in a given character class in the current locale

text: What could be way to retrieve a list of all the characters in a given character class (like `blank`, `alpha`, `digit`...) in the current locale. For instance,               LC_ALL=en_GB.UTF-8 that-command blank      ideally, would display something like:                     09 U+0009 HORIZONTAL TAB           20 U+0020 SPACE     e1 9a 80 U+1680 OGHAM SPACE MARK     e1 a0 8e U+180E MONGOLIAN VOWEL SEPARATOR     e2 80 80 U+2000 EN QUAD     e2 80 81 U+2001 EM QUAD     e2 80 82 U+2002 EN SPACE     e2 80 83 U+2003 EM SPACE     e2 80 84 U+2004 THREE-PER-EM SPACE     e2 80 85 U+2005 FOUR-PER-EM SPACE     e2 80 86 U+2006 SIX-PER-EM SPACE     e2 80 88 U+2008 PUNCTUATION SPACE     e2 80 89 U+2009 THIN SPACE     e2 80 8a U+200A HAIR SPACE     e2 81 9f U+205F MEDIUM MATHEMATICAL SPACE     e3 80 80 U+3000 IDEOGRAPHIC SPACE      And in the C locale could display something like:               09 U+0009 HORIZONTAL TAB     20 U+0020 SPACE      That is, the representation of the character in the locale in terms of arrays of bytes, (like UTF-8 in the first example, and single byte in the second), the equivalent Unicode character codepoint and a description.


title: update-grub in grml

text: I converted a machine from a single disk to mdadm RAID1. I did this nearly like it's described in Raid1 on a running system. Before, I tried to make the same changes not within the running system, but in grml. update-grub failed. It complained /dev couldn't be found. Why is update-grub not possible within a live-cd?


title: Which version of linux to practise unix scripting/programming?

text: I was using cygwin, but its frustrating to use. It does not have many programs and is confusing. I want to get some linux distro in which I can use bash and run most commonly used commands, scripts etc. EDIT - Which version of linux is smallest and good enough to learn unix ? My requirements - it should have all or most programs needed to do bash programming and scripting. It should NOT be like my cygwin which has no programs like more, lp etc and which keeps on causing installation errors and such. How is Slitaz in terms of popularity, functionality and development efforts ? I was interested because I was looking for a small sized linux with enough programs to do beginner bash programming/scripting.