title: Are there any drawbacks from using mount --bind as a substitute for symbolic links?

text: Symlinks have limitations in how functions like `ls`, `mv`, and `cp` can operate on them because unlike shell initiated commands like `cd`, these functions do not have information about how the user accessed the directory with respect to the logical path (see related post). It seems like using the `mount --bind` option instead can get an around this, offering increased functionality and compatibility with samba and other file servers because the mounted directory will then have two independent physical paths, instead of a link. I would like to replace all of my symbolic links with references using the `mount --bind` option but this would mean mounting over 150 points in fstab. Are there any performance issues that could potentially arise from this or any other drawbacks that I should consider? Thanks for any advice.


title: bash: dynamic environment control

text: I have an application which modifies environment variables. The intent is to launch a bash shell with a modified context-specific environment. When my application modifies the environment, and exec()s "bash --noprofile --norc" with the modified environment then I almost get the behavior I want, except that aliases are dropped. If I log in and open a shell directly from the OS, I get the "normal" aliases, but if my application launches a bash, then I don't get any aliases because the initialization files are skipped. Is there any way to have bash initialize from a dynamic source? In other words, it would be helpful if I could have my application launch "bash" with all its various user/facility settings (including aliases) and then at the end of that, source the differences that my application needs to apply. Ideally, this would leave open a shell prepped and ready to go for my users. I'm not finding this (or perhaps understanding it) from the man page. In an ideal world, we could refactor the user/factory settings to be more reentrant (aware of the application, and skip reinitialization steps that don't need to happen again); but in practice this is turning out to be a little bit of a hassle. Any suggestions? Thanks.


title: X11 blank vs dpms off

text: I've been playing around with the dpms/blanking settings on a version of Linux built via yocto. Something odd I've noticed is that "blank" and "dpms off" both put the monitor to sleep. I had thought blanking would just, well, blank the screen, and not actually power off the monitor. Am I mistaken? Blanking test:               $ xset s blank     $ xset s activate      DPMS test               $ xset dpms force off      What I'd like is to just blank the screen on a short interval and then actually power off the monitor after a longer interval. Perhaps I should look at a minimal black screensaver instead of using the built in blank.


title: vmstat IO stats: why the high bo during a download?

text: On my RHEL 4 machine, I was downloading a huge file (2.5GB)..I was checking the output of vmstat and was especially curious about seeing the disk IO using bi and bo. I know iostat is a better tool suited for this but didn't have it installed on this machine. Anyways, I was expecting bi (bytes in) to be high during the download but found the exact opposite...bo (bytes out) was very high during the download where as bi was mostly 0 with occasional numbers?? Also, without iostat, is there a better tool than vmstat that is available Out of the Box in a Red Hat machine?


title: How can I chroot into a filesystem with a different architechture?

text: I'm trying to `chroot` into a Arch Linux `ARM` filesystem from `x86_64`. I've seen that it's possible to do using static `qemu` by copying the binary into the chroot system:               $ cp /usr/bin/qemu-arm archarm-chroot/usr/bin          But despite this I always get the following error:               chroot: failed to run command ‘/bin/bash’: Exec format error      I know this means that the architectures differ. Am I doing something wrong?


title: How can I get the GNU screen command to automatically start with every BusyBox ash session?

text: On an embedded device with BusyBox installed I want to set it up so that the gnu screen command is automatically started when any BusyBox session is started. I have seen that I can add the screen command into the `/etc/profile` file but are there any other ways of doing this?


title: Can Safecopy Help Me Recover Data from a Drive that I can not Mount?

text: I have an old hard drive that I put data on, but it died when I tried to retrieve it, and it tells me I have to format it under Windows. Running on Linux now, can Safecopy help me even though I can not mount it? This is the error I get when I try to mount it:               Error mounting: mount exited with exit code 13: ntfs_attr_pread_i: ntfs_pread failed: Input/output error     Failed to read vcn 0x0: Input/output error     Failed to mount '/dev/sdb1': Input/output error     NTFS is either inconsistent, or there is a hardware fault, or it's a     SoftRAID/FakeRAID hardware. In the first case run chkdsk /f on Windows     then reboot into Windows twice. The usage of the /f parameter is very     important! If the device is a SoftRAID/FakeRAID then first activate     it and mount a different device under the /dev/mapper/ directory, (e.g.     /dev/mapper/nvidia_eahaabcc1). Please see the 'dmraid' documentation     for more details. It says input output error... but I thought that was why Safecopy was made? Any info would be great.


title: Ran out of inodes on NFS

text: I have a RHEL 6 box with an NFS mount, mounted using autofs. I copied a big folder, with a lot of small files there, and used up all of my inodes, but I still have 80% of my storage space left, this is a real pain! What is the easiest way out of this? I'd prefer not to have to remove anything from the NFS mount, and resizing isn't really an option right now. Is there some mount options or some other trick to be able use this NFS mount?


title: Redirect stderr from an already running script

text: I've been running a script for several days now. I redirected stdout to `$HOME/mylog`, but didn't redirect stderr since I thought there would be nothing on it. Suddenly thousands of lines started coming out on stderr, so I suspended the job. Is there a way I can redirect stderr to `$HOME/myerr` from now on, without needing to restart the script? I have sudo access on the box and it's OS X. Perhaps something using dtools trapping? I cannot lose the work the script has done so far and restart it from scratch. Is there a way to "dump the in-memory objects" on disk, freeze the program, edit the variables (e.g. the file descriptors) and _resume_ with the new context?


title: DHCP and WiFi Connectivity

text: If WiFi Dongle is associated successfully to Access-Point then is there any way to get notification ? I want to run some script (dhclient), if and only if, association is successful. Only way, that I know, is to record the log of `wpa_supplicant` with verbose mode, and search for the keyword `EAPO authentication completed successfully`. But, I guess, there must be some other way to do so. command-line solution is required as I normally work in CUI. I'm using Ubuntu-13.10.


title: vim - open file and goto line number using <filename>:<line nbr>:

text: Several tools such as `grep`, `py.test`, etc ... use the pattern `<FileName>:<line number>:` to point to errors. For example:               ; grep -Hn Common setup.cfg     setup.cfg:11:    Common      How can I modify vim and gvim so that I can invoke them like so:               gvim setup.cfg:11:      instead of               gvim setup.cfg +11      I know that I can write a small shell script that would parse things but I wonder if there is an easier way.


title: Learning the Unix/Linux Kernel

text: I've been reading The Design of the UNIX OS by Maurice J Bach. It's good overall. However, I learn better with audio/visual aids so does anyone know some good video lecture series or tutorials for either Unix or the Linux kernel? I would also like to walk through the kernel code after I've learnt the basics of the kernel. So any suggestions are welcome.


title: Login to super user for running script

text: I have `sample.sh` script in `/u01/dump` location. I'm running it from root. My requirement is while running the `sample.sh` script it has to be login as oracle1 user using SU (super user) and display all files in `/u02/dba/` directory.


title: How can I view files in zip using putty?

text: I want to view file list in zip archive using putty without unzip the archive. Is it possible?


title: Another account with same uid as root gets prompted to set new password for root, not itself

text: After upgrading the os from 5300-06 to 5300-11, this weird behaviour happened. My system had another unix account, let's call it " **abc** ", purposely configured its uid to **0** for working as a **root** with all its authorities. It has been run like this for years and worked completely fine. However after the upgrade, when abc's password expires, rather than prompting immediately after its successful login for a new password, it is now asking to change " **root** "'s password, and it really is changing root's password not abc's. If I change **abc** 's uid to another unique id, it will successfully says to change **abc** 's password when prompted. There are a lot of reasons why I cannot change **abc** 's uid. So what I'm trying to find out is, why is this happening and how can I " _fix_ " it? Is it really caused by the OS upgrade?


title: Open signed PDFs in Linux

text: We have some PDF files which are secured by a **.pfx** certificate. On Windows we can use Adobe Reader to read these PDF files (with previously imported certificate). I've googled for a long time but I can't find a PDF reader which can open this.


title: Is killing processes created on startup safe?

text: I've just got a vserver running debian 7 and whenever I start the server and call the `top` command, there are very many processes that were started automatically on startup. Can I kill them or are they critical for general functionality of the vserver?


title: Populate an entire pre-configured workspace in i3wm

text: Is it possible with I3Wm to populate an entire workspace with determined size, position and commands for each window? I know I can do `i3-msg "exec xterm -e 'ls; bash'"` to create a new window, but I can't specify his position and size. Maybe there is also an alternative by declaring via JSON the layout or something like that?


title: How to flash firmware under Linux in practice?

text: Well, I am feeling too old for jumping through several burning hoops to upgrade several firmwares via the usual vendor-specific way: Download some DOS tools, waste some time creating a (Free-)DOS boot medium and wasting more time to make the BIOS actually boot from that and finally flash the firmware upgrade. This is so 1980-ies. I come across some linux flash tool from the Coreboot project. It seems to support various FLASH-chips. But how does it work in practice? I guess there are some pitfalls converting vendor supplied firmware upgrades into the right format. Or what about indentifying the right destination chip? Currently I probably have to upgrade for example:   * the firmware of some Seagate 1.5 TB disks   * the firmware of an old Abit Athlon 64 board (Award bios)   * Bios/Embedded-Controller-Bios of a Thinkpad How do you upgrade your devices firmware at a Linux system?


title: External tablet input devices for Linux (Inkscape/Gimp)?

text: What are good external tablet input devices for Linux? It should be used for more convenient use of Inkscape and Gimp. Some characteristics that are useful, I guess:   * connected via USB   * included pen with some buttons   * tablet should only be sensitive to pen touches   * Open-source drivers (a must)   * some OS engagement by the vendor Open questions:   * What are good sizes of such tablets in practice?   * Is there is some good guide how to setup it under Linux/X?   * What are other great programs that are really easier to use with a tablet?


title: Start X as a user other than root

text: I know some distro's (Moblin? ) have X starting as a user other than root already... What is required to do this? What steps need to be taken? _I don't think it matters but I think X is started by KDM on my system and I'm running Arch Linux_


title: How to create an upstart process in Ubuntu?

text: I am trying to create a process to be automatically started and maintained by Ubuntu's upstart (Ubuntu 12.04). I have been looking at this page as well as on this page and I am aware of the upstart cookbook and upstart stanzas. Using especially the information from the first two likes, I did the following to incorporate such a process. First, I created a file `/etc/init/testservice.conf` with the following content:               # myservice - myservice job file          description "my service description"     author "Me <myself@i.com>"          # Stanzas     #     # Stanzas control when and how a process is started and stopped     # See a list of stanzas here: http://upstart.ubuntu.com/wiki/Stanzas#respawn          # When to start the service     start on runlevel [2345]          # When to stop the service     stop on runlevel [016]          # Automatically restart process if crashed     respawn          # Essentially lets upstart know the process will detach itself to the background     #expect fork          chdir /home/user/testcode          # Start the process     exec python mycommand.py      with some simple dummy python code `mycommand.py` residing in the directory `/home/user/testcode`. Checking with `initctl list` or `ps` I see that the command is not yet running. Therefore, I tried to start it 'manually' according to this page with               start testservice      which produced the following output               start: Rejected send message, 1 matched rules; type="method_call", sender=":1.88" (uid=1000 pid=9103 comm="start testservice ) interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)" requested_reply="0" estination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init")      but did not start the process `mycommand.py`. What am I doing wrong? How to tell `ubuntu` and/or `upstart` to run the command?


title: Linux + replace STRING/WORD in file according to rule

text: My target is to replace any word/string/Any characters in file with new word/string according to the following rules:   1. If numeric characters on the left side of word/string then we not replace the word   2. If numeric characters on the right side of word/string then we not replace the word remark - numeric means any number or [a-z] or [A-Z] The following Example described file before , and file after: I want to replace the word "$$OLD_WORD$$" with "&&NEW_WORD&&" example 1 - file Before replacement                 more file             ABC$$OLD_WORD$$ABC       $$OLD_WORD$$GG       $$OLD_WORD$$       1$$OLD_WORD$$      example 2 - file after replacement                 more file            ABC$$OLD_WORD$$ABC       $$OLD_WORD$$       &&NEW_WORD&&       1$$OLD_WORD$$      So in order to replace the word regarding the rules (1,2) that I mentioned I write the following syntax (this Perl command exists in my ksh script)                    perl -pe 'next if /^#/; s/(\Q|[[:^alnum:]])$ENV{OLD_TEXT}(\E|[[:^alnum:]])/$1$ENV{NEW_TEXT}$2/g' file      But this perl command not does the replacement as example 2 !!! The following Example described what I get from my Solaris/linux machine:                   export OLD_TEXT='$$OLD_WORD$$'         export NEW_TEXT='&&NEW_WORD&&'               perl -pe 'next if /^#/; s/(\Q|[[:^alnum:]])$ENV{OLD_TEXT}(\E|[[:^alnum:]])/$1$ENV{NEW_TEXT}$2/g' file                               &&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&                  &&NEW_WORD&&ABC$&&NEW_WORD&&$&&NEW_WORD&&OLD_&&NEW_WORD&&WORD$&&NC               &&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&    &&NEW_WORD&&$&&NEW_WORD&&$&&NEW_WORD&&OLD_&&NEW_WORD&&           &&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&&&NEW_WORD&&     &&NEW_WORD&&1$&&NEW_WORD&&$&&NEW_WORD&&OLD_&&NEW_WORD&      **Please advice what I need to fix in my perl syntax in order to get results as example 2?** .


title: How can one provide colour to tab completion in tcsh?

text: (Crossposted from StackOverflow.com) This question and the answer teach us how to introduce colour into tcsh prompts. This webpage explains nicely how to get colour into any output of the `echo` command:               > echo \\e[1\;30mBLACK\\e[0m     BLACK     > echo '\e[1;30mBLACK\e[0m'     BLACK      The word 'BLACK' in the example above is printed with a black (or darkgrey) foreground colour (depending on the overall color scheme). Now I'd like to introduce this into the `[TAB]` command autocompletion feature of `tcsh`. I tried:               complete testcmd 'p/*/`echo '"'"'\e[1;30mf834fef\e[0m'"'"'`/'      And I get:               > testcmd [TAB]     > testcmd ^[\[1\;30mf834fef^[\[0m      Obviously the characters lose their special meaning. Hopefully I just did not get the escaping right. But I tried several other ways. So any help is appreciated. The real use case is that I've got a command completion that offers three different types of completions and I'd like to visually distinguish the types. Also the alternatives are computed by an external command. That is why I need the completion to use the backticks with an external command, such as `echo`. I don't care about the details of this command. If you make it work in any way with the `tcsh`'s `complete` command I'll probably be able to adapt (thinking `perl -pe` wrappers and such). The reason why I believe this _has_ to work somehow is that the tcsh itself offers coloured command completion if you e.g. type `ls [TAB]`. That works correctly in my setup. Also you can use `ls -1F` inside the autocompletion and the colours that `ls` outputs are also piped through. An example would be:               complete testcmd 'p/*/`ls -1F`/'      Update: As user mavin points out on stackoverflow, the colourization of `ls` in this example is indeed not piped through. The colours of `ls` are lost, but the auto completion can reapply colours according to LS_COLOURS variable based on hints such as the `/` and `*` marker endings as added by the ls. This can be verified by doing               complete testcmd 'p/*/`ls --color -1`/'      which fails to provide colour, and only provides garbled output. (Literally pipes through the escape character sequences) I'm on `tcsh` version 6.13.00 Any ideas? Pointers?


title: What is the equivalent for 'www-data' for CentOs?

text: CentOs doesn't recognise www-data but want to change ownership on my files folder. All my folders are owned by root at the moment. Confused as to what should be owned by apache and what she be owned by me the root user? Also when it says root root does that mean root user me and group apache root?


title: Does Android's implementation of SELinux's M.A.C. inhibit root apps with root privileges from accessing app data?

text: **Starting with Android 4.4 SELinux's MAC is enforced. Does this mean that if an app somehow can get installed and exploit the kernel to get root privileges, that MAC will still prevent that app with root privileges from accessing private app data?** Android Documentation says: SELinux can be used to label these devices so the process assigned the root privilege can write to only those specified in the associated policy. In this way, the process cannot overwrite data and system settings outside of the specific raw block device. - http://source.android.com/devices/tech/security/se-linux.html#use-cases As a reference I am implementing a Mobile Device Management system and in the process I have to determine how secure Android OS is itself. That is why I need to know how secure corporate data stored on a device is to root-kits, spyware, and other malware.


title: How can Linux detect automatically if kernel must boot on dev hdc or hda

text: I have an industrial PC mounting Linux. These PC is delivered in two version, each with slightly different internal board and depending on the board type the disk inside the PC is see as hda or hdc. Until now, to select between the two type of disk boot I simply put two entry inside the grub menu.lst like show below, so at the first start of the PC the maintenance people will select the correct device which will be memorize for future reboot.               default = 0     timeout = 9          title Linux 2.4.34 ( hda )             root (hd0,0)             kernel /boot/vmlinuz-2.4.34 ro root=/dev/hda1 console=ttyS0,9600 console=tty0 apm=off          title Linux 2.4.34 ( hdc )             root (hd0,0)             kernel /boot/vmlinuz-2.4.34 ro root=/dev/hdc1 console=ttyS0,9600 console=tty0 apm=off      But in most cases this type of PC are delivered without screen and keyboard and the maintenance people are not able to select the boot option so I'm looking for a way that allow the PC to check for the correct boot device before loading the kernel. In pratical term I need that the boot procedure check if the disk is see as /dev/hdc or as /dev/hda in order to call the boot option with the right value for root device ( ie root=/dev/hda1 or root=/dev/hdc1 ) The problem is that I have no idea if that is possible and how to do that. Someone have some suggestion about this topic ?


title: Why doesn't the output get redirected into the file?

text: have the following command line that outputs vmstat every second with a time stamp on each line via the perl script:               vmstat 15 | /home/Beer/addtimestamp.pl > File_1       the contents of the addtimestamp.pl:               !/usr/bin/perl while (<>) { print localtime() . ": $_"; }      So why doesn't the output get redirected to the "File_1" file? It works perfectly when I don't, it prints out the output perfectly every second with no issues at all.


title: linux mint - loud system beep on laptop

text: I installed the newest Linux mint on My BTO W271EU laptop. All Works well, for a couple of minutes. Then the system beeps start. Really loud and continuously. Other symptoms are a flashing caps Lock and num Lock light. After a few minutes the PC shuts down. Without warning. This occurs after 5 minutes. Sometimes after An hour An sometimes I can use My laptop for Days without It happening. I already disabled the pcspkr. And added It To the blacklist (as found on mighty Google). But that doesn't work. ## edit: I also noticed that when the Laptop starte beeping and shut it self down. The beeping also occurs on startup. Once the kernel is loaded it starts beeping continiously. Again untill it shuts itself down. I have the problem with power cord plugged in and plugged out. Any ideas?


title: Copying a directory to multiple users home dir and changing user/group ownership

text: On my Ubuntu server there are about 150 shell accounts. All usernames begin with the prefix u12.. I have root access and I am trying to copy a directory named "somefiles" to all the home directories. After copying the directory the user and group ownership of the directory should be changed to user's. Username, group and home-dir name are same. How can this be done?


title: Fedora 15 won't remember wireless password

text: I just installed Fedora 15 beta with Gnome 3. I've done all the updates. The networking applet asks for the wireless password every time it connects. I found this bug, which says that the issue is fixed in gnome- keyring-2.91.92-1.fc15. I have version 3.0.1-1.fc15, so this shouldn't be an issue. Is there any other reason why the keyring wouldn't store the password?


title: How do I remove a Read-only file system from a usb drive

text: During an ill-fated attempt to get tinycore linux to boot from a USB drive I managed to create a bunch of files that I now cannot remove.               fortino@rebel:/media/working/boot/isolinux$ rm *.*     rm: cannot remove `boot.cat': Read-only file system     rm: cannot remove `boot.msg': Read-only file system     rm: cannot remove `isolinux.bin': Read-only file system     rm: cannot remove `isolinux.cfg': Read-only file system      I tried giving myself w and x permission for the files but that didn't appear to work. What is the best way to clean these files off of this USB drive? Thank you


title: Indirection on a Bash array

text: Is there a possibility to write the following script without the loop?               IPv4_first=1.1.1.1     IPv4_second=2.2.2.2     IPv4_third=3.3.3.3          IPv4_all=()           for var in ${!IPv4_@}     do        IPv4_all+=(${!var})     done          printf "'%s'\n" "${IPv4_all[@]}"      Something like:               IPv4_all=${!${!IPv4_@}}


title: Is there some kind of "patterns" when coding bash scripts?

text: In Java, we have Javadoc and some different styles when programming. In Python, there's pep8. I'm creating some bash scripts for my own use, and would like to know from you, experienced bash users, if there's some kind of "pattern" like indentation, documentation for functions, etc. A book or a website with some references.


title: What is the alsamixer of Pulse Audio?

text: I just installed Pulse Audio over my ALSA installation. Is there a Pulse Audio equivalent of alsamixer that I can use for tasks such as changing the microphone gain?


title: Isn't $HOME supposed to be the location of the user's home directory?

text: I'm having trouble with a web application I'm writing: The web application, which runs as user `nobody`, needs to launch an `inkscape` process to manipulate some SVG files. Because this runs as user `nobody`, there is no home directory. What I am doing is creating a temporary directory under `/tmp` and trying to set that as the home directory via `export HOME=/tmp/someUniqueId`. I then set a few things in that "temporary" home directory, like a symlink `.fonts` to the folder for the font files to use. I know this works for finding the `~/.fonts` directory. But when I launch Inkscape, all I get is a message that Inkscape could not create the `.inkscape` directory: ![Cannot create directory /.inkscape](http://i.stack.imgur.com/wENAF.png) Doesn't `$HOME` set the location of my home directory? Why is Inkscape still trying to access `/` as my home directory?


title: How to check if libfftw3_threads.so.3.2.4 shared library was compiled for pthreads or for OpenMP?

text: There is FFTW library installed by an administrator system-wide, in `/usr/lib64`, and it includes `/usr/lib64/libfftw3_threads.so.3.2.4`. When I compiled this library myself, before it was installed by sysadmin, I have noticed that you have to choose between **OpenMP** and **pthreads** version: >   * `\--enable-openmp`: Like `\--enable-threads`, but using OpenMP compiler > directives in order to induce parallelism rather than spawning its own > threads directly. Useful especially for programs already employing such > directives, in order to minimize conflicts between different parallelization > mechanisms. Use either `\--enable-openmp` or `\--enable-threads`, not both; > in either case the multi-threaded FFTW interface/library (see Multi-threaded > FFTW) is compiled (with different back ends). > The distribution is Gentoo, so theoretically either is possible. How to check if said library was compiled with OpenMP support (which would be best), or with pthreads?


title: Forcing compton to free directory

text: I often have trouble unnounting filesystems because `compton` is keeping a subdirectory open. Here is one line from `lsof` I have right now:               compton   30043            valmi  cwd       DIR              254,0    32768       7485 /media/truecrypt1/videos      I cannot for the life of me figure what it is doing with this directory (it is not used by any other process nor was it ever opened in any application besides bash). So far, I always just ended up restarting X when this happened, but I would love for someone to tell me how to make `compton` understand that it should let go my directory, or as a consolation tell me what it is doing with it. If this is relevant, this is compton-git 20121102-2 from Debian stable, with 3.5.0-7 and everything up-to-date.


title: install php5 with readline support on debian wheezy

text: php5-cli does not come with readline support on debian wheezy. this means that the interactive php shell (run as `$ php -a`) does not have a prompt (`php >`), instead it just says `Interactive mode enabled` and then leaves the cursor on a blank line. i can execute php but it is awkward, eg `<? echo 'hi'; ?>` `enter``ctrl``d` and it will excute a php command, but this is no way near as nice as having the prompt with readline support. I found some instructions to install php5-cli with readline support via the dotdeb repository however i get half way and it gives an error: ### download GPG key               $ cd /tmp     $ wget http://www.dotdeb.org/dotdeb.gpg     --2013-10-13 00:12:27--  http://www.dotdeb.org/dotdeb.gpg     Resolving www.dotdeb.org (www.dotdeb.org)... 88.190.17.153     Connecting to www.dotdeb.org (www.dotdeb.org)|88.190.17.153|:80... connected.     HTTP request sent, awaiting response... 200 OK     Length: 5299 (5.2K) [application/octet-stream]     Saving to: `dotdeb.gpg'          100%[=====================================================================================>] 5,299       --.-K/s   in 0.005s            2013-10-13 00:12:28 (946 KB/s) - `dotdeb.gpg' saved [5299/5299]      ### Install GPG key               $ cat dotdeb.gpg | sudo apt-key add -     OK     $ sudo apt-get update     Ign cdrom://[Debian GNU/Linux 7.0.0 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20130505-10:47] wheezy Release.gpg     Ign cdrom://[Debian GNU/Linux 7.0.0 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20130505-10:47] wheezy Release     Ign cdrom://[Debian GNU/Linux 7.0.0 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20130505-10:47] wheezy/main amd64 Packages/DiffIndex     Ign cdrom://[Debian GNU/Linux 7.0.0 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20130505-10:47] wheezy/main Translation-en_AU     Ign cdrom://[Debian GNU/Linux 7.0.0 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20130505-10:47] wheezy/main Translation-en     Hit http://ftp.au.debian.org wheezy Release.gpg                                                                   Hit http://ftp.au.debian.org wheezy-updates Release.gpg                                                           Hit http://ftp.au.debian.org wheezy Release                                                                       Hit http://ftp.au.debian.org wheezy-updates Release                                                                                Hit http://ftp.au.debian.org wheezy/main Sources                                                                                Hit http://ftp.au.debian.org wheezy/main amd64 Packages                                                                            Hit http://ftp.au.debian.org wheezy/main Translation-en                                                           Hit http://ftp.au.debian.org wheezy-updates/main Sources                            Hit http://ftp.au.debian.org wheezy-updates/main amd64 Packages/DiffIndex     Hit http://ftp.au.debian.org wheezy-updates/main Translation-en/DiffIndex     Hit http://packages.dotdeb.org wheezy Release.gpg     Hit http://security.debian.org wheezy/updates Release.gpg     Hit http://packages.dotdeb.org wheezy Release     Hit http://security.debian.org wheezy/updates Release     Hit http://packages.dotdeb.org wheezy/all Sources     Hit http://packages.dotdeb.org wheezy/all amd64 Packages     Hit http://security.debian.org wheezy/updates/main Sources     Hit http://security.debian.org wheezy/updates/main amd64 Packages     Hit http://security.debian.org wheezy/updates/main Translation-en     Ign http://packages.dotdeb.org wheezy/all Translation-en_AU     Ign http://packages.dotdeb.org wheezy/all Translation-en     Reading package lists... Done      ### dist-upgrade               $ sudo apt-get dist-upgrade     Reading package lists... Done     Building dependency tree            Reading state information... Done     Calculating upgrade... Done     0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.      ### Test PHP in interactive mode               $ php -a     Interactive mode enabled          <?php echo 'hi'; ?>     hi$ # this is not what i want!      ### Try compiling readline support               $ sudo aptitude install php5-dev libedit-dev     No packages will be installed, upgraded, or removed.     0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.     Need to get 0 B of archives. After unpacking 0 B will be used.          $ cd ~/     $ sudo apt-get source php5-cli     Reading package lists... Done     Building dependency tree            Reading state information... Done     Picking 'php5' as source package instead of 'php5-cli'     NOTICE: 'php5' packaging is maintained in the 'Git' version control system at:     git://git.debian.org/pkg-php/php.git     Need to get 11.8 MB of source archives.     Get:1 http://packages.dotdeb.org/ wheezy/all php5 5.4.20-1~dotdeb.1 (dsc) [3,425 B]     Get:2 http://packages.dotdeb.org/ wheezy/all php5 5.4.20-1~dotdeb.1 (tar) [11.7 MB]     Get:3 http://packages.dotdeb.org/ wheezy/all php5 5.4.20-1~dotdeb.1 (diff) [121 kB]                                                Fetched 11.8 MB in 31s (374 kB/s)                                                                                dpkg-source: warning: extracting unsigned source package (php5_5.4.20-1~dotdeb.1.dsc)     dpkg-source: info: extracting php5 in php5-5.4.20     dpkg-source: info: unpacking php5_5.4.20.orig.tar.bz2     dpkg-source: info: unpacking php5_5.4.20-1~dotdeb.1.debian.tar.gz     dpkg-source: info: applying 001-libtool_fixes.patch     dpkg-source: info: applying 006-debian_quirks.patch     dpkg-source: info: applying libtool2.2.patch     dpkg-source: info: applying 019-z_off_t_as_long.patch     dpkg-source: info: applying 033-we_WANT_libtool.patch     dpkg-source: info: applying 052-phpinfo_no_configure.patch     dpkg-source: info: applying 053-extension_api.patch     dpkg-source: info: applying 054-phpinfo_dotdeb.patch     dpkg-source: info: applying 057-no_apache_installed.patch     dpkg-source: info: applying 100-recode_is_shared.patch     dpkg-source: info: applying 113-php.ini_securitynotes.patch     dpkg-source: info: applying sybase-alias.patch     dpkg-source: info: applying qdbm-is-usr_include_qdbm.patch     dpkg-source: info: applying session_save_path.patch     dpkg-source: info: applying php-fpm-man-section-and-cleanup.patch     dpkg-source: info: applying fpm-config.patch     dpkg-source: info: applying php-fpm-sysconfdir.patch     dpkg-source: info: applying temporary-path-fixes-for-multiarch.patch     dpkg-source: info: applying php-5.3.9-mysqlnd.patch     dpkg-source: info: applying php-fpm-listen-on-unix-socket.patch          $ cd php5-5.4.20/ext/readline     $ pwd     /home/peter/php5-5.4.20/ext/readline     $ ls     config.m4  CREDITS  php_readline.h  readline.c  readline_cli.c  readline_cli.h  README.libedit  tests      ### Run phpize               $ sudo phpize     Configuring for:     PHP Api Version:         20100412     Zend Module Api No:      20100525     Zend Extension Api No:   220100525          $ pwd     /home/peter/php5-5.4.20/ext/readline          $ ls     acinclude.m4    build         config.m4   configure.in  ltmain.sh        mkinstalldirs   readline_cli.c  run-tests.php     aclocal.m4      config.guess  config.sub  CREDITS       Makefile.global  php_readline.h  readline_cli.h  tests     autom4te.cache  config.h.in   configure   install-sh    missing          readline.c      README.libedit      ### Configure               $ sudo ./configure      checking for grep that handles long lines and -e... /bin/grep     checking for egrep... /bin/grep -E     checking for a sed that does not truncate output... /bin/sed     checking for cc... cc     checking whether the C compiler works... yes     checking for C compiler default output file name... a.out     checking for suffix of executables...      checking whether we are cross compiling... no     checking for suffix of object files... o     checking whether we are using the GNU C compiler... yes     checking whether cc accepts -g... yes     checking for cc option to accept ISO C89... none needed     checking how to run the C preprocessor... cc -E     checking for icc... no     checking for suncc... no     checking whether cc understands -c and -o together... yes     checking for system library directory... lib     checking if compiler supports -R... no     checking if compiler supports -Wl,-rpath,... yes     checking build system type... x86_64-unknown-linux-gnu     checking host system type... x86_64-unknown-linux-gnu     checking target system type... x86_64-unknown-linux-gnu     checking for PHP prefix... /usr     checking for PHP includes... -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib     checking for PHP extension directory... /usr/lib/php5/20100525     checking for PHP installed headers prefix... /usr/include/php5     checking if debug is enabled... no     checking if zts is enabled... no     checking for re2c... re2c     checking for re2c version... 0.13.5 (ok)     checking for gawk... no     checking for nawk... nawk     checking if nawk is broken... no     checking for libedit readline replacement... yes, shared     checking for tgetent in -lncurses... no     checking for tgetent in -ltermcap... yes     checking for readline in -ledit... yes     checking for rl_callback_read_char in -ledit... yes     checking for rl_on_new_line in -ledit... no     checking for rl_completion_matches... no     checking how to print strings... printf     checking for a sed that does not truncate output... (cached) /bin/sed     checking for fgrep... /bin/grep -F     checking for ld used by cc... /usr/bin/ld     checking if the linker (/usr/bin/ld) is GNU ld... yes     checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B     checking the name lister (/usr/bin/nm -B) interface... BSD nm     checking whether ln -s works... yes     checking the maximum length of command line arguments... 1572864     checking whether the shell understands some XSI constructs... yes     checking whether the shell understands "+="... yes     checking how to convert x86_64-unknown-linux-gnu file names to x86_64-unknown-linux-gnu format... func_convert_file_noop     checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop     checking for /usr/bin/ld option to reload object files... -r     checking for objdump... objdump     checking how to recognize dependent libraries... pass_all     checking for dlltool... no     checking how to associate runtime and link libraries... printf %s\n     checking for ar... ar     checking for archiver @FILE support... @     checking for strip... strip     checking for ranlib... ranlib     checking for gawk... (cached) nawk     checking command to parse /usr/bin/nm -B output from cc object... ok     checking for sysroot... no     checking for mt... mt     checking if mt is a manifest tool... no     checking for ANSI C header files... yes     checking for sys/types.h... yes     checking for sys/stat.h... yes     checking for stdlib.h... yes     checking for string.h... yes     checking for memory.h... yes     checking for strings.h... yes     checking for inttypes.h... yes     checking for stdint.h... yes     checking for unistd.h... yes     checking for dlfcn.h... yes     checking for objdir... .libs     checking if cc supports -fno-rtti -fno-exceptions... no     checking for cc option to produce PIC... -fPIC -DPIC     checking if cc PIC flag -fPIC -DPIC works... yes     checking if cc static flag -static works... yes     checking if cc supports -c -o file.o... yes     checking if cc supports -c -o file.o... (cached) yes     checking whether the cc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes     checking whether -lc should be explicitly linked in... no     checking dynamic linker characteristics... GNU/Linux ld.so     checking how to hardcode library paths into programs... immediate     checking whether stripping libraries is possible... yes     checking if libtool supports shared libraries... yes     checking whether to build shared libraries... yes     checking whether to build static libraries... no     configure: creating ./config.status     config.status: creating config.h     config.status: executing libtool commands      ### Make               $ sudo make     /bin/bash /home/peter/php5-5.4.20/ext/readline/libtool --mode=compile cc  -I. -I/home/peter/php5-5.4.20/ext/readline -DPHP_ATOM_INC -I/home/peter/php5-5.4.20/ext/readline/include -I/home/peter/php5-5.4.20/ext/readline/main -I/home/peter/php5-5.4.20/ext/readline -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /home/peter/php5-5.4.20/ext/readline/readline.c -o readline.lo      libtool: compile:  cc -I. -I/home/peter/php5-5.4.20/ext/readline -DPHP_ATOM_INC -I/home/peter/php5-5.4.20/ext/readline/include -I/home/peter/php5-5.4.20/ext/readline/main -I/home/peter/php5-5.4.20/ext/readline -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/peter/php5-5.4.20/ext/readline/readline.c  -fPIC -DPIC -o .libs/readline.o     /bin/bash /home/peter/php5-5.4.20/ext/readline/libtool --mode=compile cc  -I. -I/home/peter/php5-5.4.20/ext/readline -DPHP_ATOM_INC -I/home/peter/php5-5.4.20/ext/readline/include -I/home/peter/php5-5.4.20/ext/readline/main -I/home/peter/php5-5.4.20/ext/readline -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /home/peter/php5-5.4.20/ext/readline/readline_cli.c -o readline_cli.lo      libtool: compile:  cc -I. -I/home/peter/php5-5.4.20/ext/readline -DPHP_ATOM_INC -I/home/peter/php5-5.4.20/ext/readline/include -I/home/peter/php5-5.4.20/ext/readline/main -I/home/peter/php5-5.4.20/ext/readline -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/peter/php5-5.4.20/ext/readline/readline_cli.c  -fPIC -DPIC -o .libs/readline_cli.o     /home/peter/php5-5.4.20/ext/readline/readline_cli.c:54:31: fatal error: readline/readline.h: No such file or directory     compilation terminated.     make: *** [readline_cli.lo] Error 1      As you can see it terminates with a fatal error complaining that it can't find `readline.h`. any idea what i am doing wrong? could it just be that it will not work on debian wheezy (7)? the dotdeb page instructions only talk about debian squeeze (6)...


title: Error installing Fedora 19

text: I'm trying to install Fedora 19. After my computer booted from installation DVD for about 20 minutes, it displays white screen with 'Oh no! Something has gone wrong.' message. I've tried 3 times and it still persists.


title: Convert any Date format in unix

text: How can I convert any user inputted date into `yyyy/mm/dd`? For example user can input date in one of the following formats `20120121` , `2012-01-21`, `01/21/2012`, `01/21/2012` etc. But I need to convert any of the date entered by user into `yyyy/mm/dd` (2012/01/2012). How? This is the script I was using , but it is not working.               echo "Please enter the date: "     read X     a=$X+"%y/%m/%d"     echo $a


title: No wireless interface detected in Linux

text: I'm using Backtrack5R3 via bootable CD and getting `no wireless interface found` output. These are the o/p of commands by which you can get details of my problem. My laptop model is Lenovo b490(20205).               root@bt:~# iwconfig         lo        no wireless extensions.              eth0      no wireless extensions.          root@bt:~# ifconfig     eth0      Link encap:Ethernet  HWaddr 3c:97:0e:8d:ef:29                 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)               Interrupt:42 Base address:0x6000           lo        Link encap:Local Loopback                 inet addr:127.0.0.1  Mask:255.0.0.0               inet6 addr: ::1/128 Scope:Host               UP LOOPBACK RUNNING  MTU:16436  Metric:1               RX packets:69 errors:0 dropped:0 overruns:0 frame:0               TX packets:69 errors:0 dropped:0 overruns:0 carrier:0               collisions:0 txqueuelen:0                RX bytes:15785 (15.7 KB)  TX bytes:15785 (15.7 KB)          root@bt:~# airmon-ng               Interface   Chipset     Driver                   root@bt:~# lspci     00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)     00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)     00:14.0 USB Controller: Intel Corporation Panther Point USB xHCI Host Controller (rev 04)     00:16.0 Communication controller: Intel Corporation Panther Point MEI Controller #1 (rev 04)     00:1a.0 USB Controller: Intel Corporation Panther Point USB Enhanced Host Controller #2 (rev 04)     00:1b.0 Audio device: Intel Corporation Panther Point High Definition Audio Controller (rev 04)     00:1c.0 PCI bridge: Intel Corporation Panther Point PCI Express Root Port 1 (rev c4)     00:1c.1 PCI bridge: Intel Corporation Panther Point PCI Express Root Port 2 (rev c4)     00:1c.3 PCI bridge: Intel Corporation Panther Point PCI Express Root Port 4 (rev c4)     00:1d.0 USB Controller: Intel Corporation Panther Point USB Enhanced Host Controller #1 (rev 04)     00:1f.0 ISA bridge: Intel Corporation Panther Point LPC Controller (rev 04)     00:1f.2 SATA controller: Intel Corporation Panther Point 6 port SATA AHCI Controller (rev 04)     00:1f.3 SMBus: Intel Corporation Panther Point SMBus Controller (rev 04)     02:00.0 Network controller: Broadcom Corporation Device 4365 (rev 01)     03:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 07)          root@bt:~# lshw -c network       *-network UNCLAIMED                 description: Network controller            product: Broadcom Corporation            vendor: Broadcom Corporation            physical id: 0            bus info: pci@0000:02:00.0            version: 01            width: 64 bits            clock: 33MHz            capabilities: pm msi pciexpress bus_master cap_list            configuration: latency=0            resources: memory:f0500000-f0507fff       *-network            description: Ethernet interface            product: RTL8111/8168B PCI Express Gigabit Ethernet controller            vendor: Realtek Semiconductor Co., Ltd.            physical id: 0            bus info: pci@0000:03:00.0            logical name: eth0            version: 07            serial: 3c:97:0e:8d:ef:29            size: 10MB/s            capacity: 1GB/s            width: 64 bits            clock: 33MHz            capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation            configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=half firmware=rtl_nic/rtl8168e-3.fw latency=0 link=no multicast=yes port=MII speed=10MB/s            resources: irq:42 ioport:2000(size=256) memory:f0404000-f0404fff memory:f0400000-f0403fff      Let me know if you require more details.


title: Add users from dat file

text: I have a dat file with names. These are the names of users I must add, without groups or passwords. Ofcourse i have to remove all spaces. I have to add them with a bash script. Can anyone help me write the script? File:               Marianne        Earman     Justina Dragaj     Mandy   Mcdonnell     Conrad  Lanfear     Cyril   Behen     Shelley Groden     Rosalind        Krenzke     Davis   Brevard     Winnie  Reich     Trudy   Worlds     Deshawn Inafuku     Claudio Loose     Sal     Pindell     Cristina        Sharper     Tricia  Kruss      My script:               #!/bin/bash     #users.dat | sed "s/\t\t*/ /g"     while read p; do       #var=$(echo $p | sed "s/\t\t*/ /g")       var= echo $p | sed '/^$/d;s/[[:blank:]]//g'       #sudo useradd $var       sudo useradd $var      done < users.dat


title: How can I print out the current keybindings in Linux/Debian?

text: How can I print out the current keybindings in Linux/Debian ? I tried               xmodmap -pp      and got the response:               xmodmap:  unable to open display ''


title: Script in C shell skipping over last else statement?

text: This is a C shell script that checks the number of arguments and if the file/directory exists. When the arguments are valid, it should go to the last else statement and print "hi", but when I run this script with the correct arguments it doesn't print anything. (but the exit status is 0)   Everything else works fine when I have invalid arguments.               if ($#argv != 2) then             echo "Two arguments required"     else             if (! -f $argv[1]) then                     echo "File does not exist"                     exit 1             else                     if (! -d $argv[2]) then                             echo "Not a valid directory"                             exit 2                     endif             endif     else                 echo "hi"     endif      Maybe it's my syntax that is wrong? Any ideas?


title: How to put syslinux on an sd card

text: I would like to know how to put syslinux on my sd card and I have tried using extlinux. However, I keep getting the message `Missing Operating System`. Please help me.


title: Multiple ACLs in Squid Proxy

text: Here is my Squid configuration file. I would like to give specific users access to specific web content, But through this configuration file, if I give permission for a specific user to access the tutorial, social networking is blocked but movie is accessible. Even if I grouped allow and deny separately and checked, the same problem continues; I can't grant access to the tutorial but still block access to movies               acl localnet src 10.1.1.0/24     acl special src "/etc/squid/special.txt" # All Access IPs     acl unlimited src "/etc/squid/unlimited.txt"        # Full Download access     acl allow_proxy src "/etc/squid/allow_proxy.txt"    # Allow Proxy sites     acl allow_social src "/etc/squid/allow_social.txt"  # Allow Social networking          acl allow_tutorial src "/etc/squid/allow_tutorial.txt"  # Allow Tutorial     acl allow_movie src "/etc/squid/allow_movie.txt"    # Allow Jobs     acl allow_jobs src "/etc/squid/allow_jobs.txt"      # Allow Movie          #Allow / Block     acl goodkey url_regex "/etc/squid/goodkey.txt"     acl proxy url_regex "/etc/squid/proxy.txt"     acl social url_regex "/etc/squid/social.txt"     acl tutorial url_regex "/etc/squid/tutorial.txt"     acl movie url_regex "/etc/squid/movie.txt"     acl jobs url_regex "/etc/squid/jobs.txt"          #Download Limit     reply_body_max_size 3000 KB localnet !unlimited     request_body_max_size 3000 KB localnet !unlimited          #Allow     http_access allow special     http_access allow goodkey          #Proxy     http_access allow allow_proxy     http_access deny proxy          #Social     http_access allow allow_social     http_access deny social          #Tutorial     http_access allow allow_tutorial     http_access deny tutorial          #Movie     http_access allow allow_movie     http_access deny movie          #Jobs      http_access allow allow_jobs     http_access deny jobs          #ACL Allow     http_access allow localnet          #And finally deny all other access to this proxy     http_access allow localhost     http_access deny all


title: Is it possible to run a webdav fuse client with no root access?

text: I have seen examples showing how to use `davfs2` under linux, but each has involved one of these things:   1. Running `mount` as root   2. Adding an entry to `/etc/fstab`   3. Running `mount.davfs` setuid, which, alas, still requires an entry in `/etc/fstab` Can this be avoided? If not, what aspect of webdav prevents it, more than for, e.g. sshfs?


title: SSH and certificates - how to connect?

text: My geeky friend has dropped me this message: _Debian instance has been created for you with IP address of`10.5.0.95`. Remember: To connect to it, you need the certificate: `ssh -i xxx.xxx admin@10.5.0.95`. The certificate is in the root home of `10.5.0.20` -> I showed you this instance and you can connect to it any time._ Unfortunately I have no idea about how to connect to this Debian instance using the given information. Those certificates and `ssh` - I can't really understand that.


title: Having some trouble authenticating via proxy in order to use apt-get successfully on a corporate network

text: Our server is on a corporate network, which requires corporate proxy authentication (e.g. enter corporate username and password). This is not an issue on the Windows machines on that network - when a web browser is opened the user is prompted to authenticate. However, when using a browser on Linux, the user is not prompted to authenticate, the browser simply shows a message saying authentication is required. Internet Access would be useful At the moment I have to walk to my desk on another floor, if I need to look something up, because I cannot get Internet access from this machine, since I cannot (or do not know how to) authenticate. It would be useful to have the ability to authenticate, so I can use a web browser. Packages cannot be updated When I attempt to perform updates using `sudo apt-get update` or `sudo apt-get install [package]`, there are errors, which I believe are caused due to lack of authentication. After performing `sudo apt-get update`, I get errors like `W: Failed to fetch [link] 401 Authorization Required`. (For some reason some http://us.archive.ubuntu.com trusty/ sources work correctly, and some throw the same error). This is a major problem, as I need to be able to update packages on the server.   * I have installed `cntlm` via `sudo apt-get install cntlm` (it works from one of the few Ubuntu repositories that randomly work).    * I edited the configuration at `/etc/cntlm.conf` and added my username, the domain and the proxy.    * I started the service (`sudo /etc/init.d/cntlm start`).   * I tested the service (`sudo cntlm -I -M http://www.google.com/`) and the response was `Config Profile 1/4... Auth not required (HTTP code: 307) Your proxy is open, you don't need another proxy`.   * I tried performing `sudo apt-get update` again and still receive the same error message. (`401 Authorization Required`)    * _(Whoops! My mistake! I see I need to configure`apt` proxy settings manually...)_   * I added the line `Acquire::http::Proxy "http://localhost:3128";` to `/etc/apt/apt.conf`.   * I restarted `cntlm`. (`sudo /etc/init.d/cntlm stop`, `sudo /etc/init.d/cntlm start`)   * I performed `sudo apt-get update` ... and it hit `0% [Waiting for headers] [Waiting for headers] [Waiting for headers] [Waiting f` - and just stopped there. **Steps Taken (after asking)**   * I performed `sudo apt-get clean`, before performing `sudo apt-get update` - this started working and then stopped at `19% [Waiting for headers]`   * I performed `sudo apt-get clean` again, before performing `sudo apt-get update` - this started working and then stopped at `0% [Waiting for headers]`   * I tried this a third time (`sudo apt-get clean`, `sudo apt-get update`) and it stopped at `20% [Waiting for headers]`   * I researched this subsequent problem and found an answer on AskUbuntu, suggesting this may be an issue with IPv6 causing ICS to halt for a while, when it receives concurrent connections.   * I checked the `/etc/sysctl.conf` file and discovered the IPv6 already appears to be disabled... (The lines `net.ipv6.conf.all.disable_ipv6 = 1`, `net.ipv6.conf.default.disable_ipv6 = 1`, and `net.ipv6.conf.lo.disable_ipv6 = 1` are already in the config file.)    * _(I'm now drawing a bit of a blank! The symptoms match the hypothesized IPv6 issue, however, if it is already disabled that doesn't seem to be able to be the cause)_   * I performed `sudo apt-get clean` and `sudo apt-get update` a fourth time _(What the hell - why not?)_ and it hung on `24% [Waiting for Headers]` this time, but first it hit a bunch of repositories. A repository which used to trigger errors did not do so now (`http://cran.rstudio.com trusty /`) but one which used to trigger errors now triggered a different error, `Received HTTP code 501 from proxy after CONNECT`.


title: merge that works at word granularity instead of line

text: The old `diff`, `patch`, and `merge` programs, and their modern descendents in the form of version control systems work great for managing source code that can be edited concurrently by multiple people. They are, however, strictly line oriented, and thus tend to fall down flat on text that is more free form. In my particular case, I'm working with `latex` files edited by multiple people, and text is constantly reflowed -- adding or subtracting a word to a paragraph alters the line boundaries for the rest of the paragraph. There are `diff` tools that highlight changes within a line (many modern GUI ones), or even handle reflowed text (`wdiff`, `git diff --word-diff`). However, I've found nothing that handles three-way-merges or patching. Does anyone know of a good tool that will do this automatically? (Yes, I could chop the text up so as to put each word (and run of white space) onto a separate line. Something like the format for `git diff --word-diff=porcelain` might not be a bad choice. But making this reversible and robust to an automated merge (including merge conflict markers) is not quite trivial). Bonus points for a `git` merge driver.


title: iostat usage and output

text: When I run the `iostat` command like this:               iostat -d      I get a result something like this:               Linux 2.6.18-238.el5 (mon01)       09/03/2011          Device:            tps   Blk_read/s   Blk_wrtn/s   Blk_read   Blk_wrtn     sda               9.83        11.88       264.67   38378414  854835288     sda1              9.83        11.88       264.67   38375658  854834320     sda2              0.00         0.00         0.00       2346        968     sdb              58.40         7.96      1552.02   25716671 5012803778     sdb1             58.40         7.96      1552.02   25715861 5012803778      If I run it again several times waiting two to three few minutes between execution I get exactly the same set of values for `tps`, `Blk_read/s` and `Blk_wrtn/s`. The `man` page for `iostat` says: > The first report generated by the iostat command provides statistics > concerning the time since the system was booted. Each subsequent report > covers the time since the previous report. If this is the case why are my `tps`, `Blk_read/s` and `Blk_wrtn/s` values not varying in the slightest? Does _"Each subsequent report"_ mean between the individual reports if running:               iostat -d 1 5      ...rather than the last time I ran `iostat -d`? I am slightly confused here.


title: Extracting queries from log file that do not include banned lines

text: I have a log file that looks something like the following:               query1 startQuery     query1 do something     query1 do something else     query2 startQuery     query1 do something banned     query2 do something     query3 startQuery     query2 endQuery 1000     query3 something else to do     query1 endQuery 2003     query3 do something     query4 startQuery     query4 endQuery 100     query3 endQuery 1434      I am finding the longest running queries:               > grep "endQuery" logfile | awk '{print $3 " " $1}' | sort -nr | head -n 3     2003 query1     1434 query3     1000 query2      However, there are certain operations known to be long, and I want to find the longest running queries that _do not_ include these operations. For example, I want to find the longest running queries that do not, in any of their log lines, include the word "banned". In this example it would output:               1434 query3     1000 query2     100 query4      In reality these log files are large and contain a lot of queries.


title: convert images to pdf: How to make PDF Pages same size

text: I did something like               convert -page A4 -compress A4 *.png CH00.pdf      But the 1st page is much larger than the subsequent pages. This happens even though the image dimensions are similar. These images are scanned & cropped thus may have slight differences in dimensions I thought `-page A4` should fix the size of the pages?


title: newgrp asks for password

text: I don't understand why `newgrp` prompts me for password when I want to change my group. I don't even know what password it is asking for but certainly not mine (user clime).               $ id     uid=500(clime) gid=501(www) groups=501(www),500(clime) context=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023     $ newgrp clime     Password: <--- huh?!      My system is centos 6.3.


title: Adding two numbers using expr

text: I'm learning Shell scripting for a diploma in IT I'm currently doing. I'm trying to write a small script that adds two numbers as shown as in one of the tutorials we were given.               echo "Enter two numbers"     read num1 num2     sum = 'expr $num1 + $num2'     echo "The sum is = $sum"      However when I give it the execution permission and run the script, it gives me this error.               sum: =. No such file or directory.     sum: expr $num1 + $num2: No such file or directory      ![enter image description here](http://i.stack.imgur.com/AOK8W.png) I tried running this on both Ubuntu and Fedora but same error occurs. Can anyone please tell me what I'm missing here?


title: Reading and searching long man pages

text: I finally got fed up when wanting to read about _bash_ 's `read` and it's `-s` option with `man bash`. I found the right spot eventually (around line 4500), but it was a frustrating as usual, since both `/read` and even `/\s-s\s` searches have way too many matches. So, the question is: How can I read long man pages efficiently, or get same information in other ways, _locally_? As a specific example, how to reach the relevant documentation after seeing `read -s pwd` in a shell script? A good answer could be a shell script snippet, or hint about some tool and how it is used, or something else entirely, as long as it helps in finding the right spot to read. Note: I'm not tagging with bash because I want the question to be about man page reading in general, even though that quite possibly is the most commonly encountered humongous man page.


title: How to highlight some text on a man page?

text: I find the manuals very difficult to read using the terminal. Is there a way to highlight specific text on the terminal? I tried piping to `gedit` using `man man | gedit`, but it opens a blank file instead. Perhaps there's some way to find text within a man page and have it highlighted?


title: Can I get individual man pages for the bash builtin commands?

text: Is there anywhere you can download a manpage for every builtin commands? I know you can just use `help` or `man bash` and search to find info about it, but I want them separated, so I can just do `man read` and get the read manpage.


title: Allocation of Swap in 64 bit UBUNTU 13.04

text: I have 256GB ssd drive, 32GB DDR RAM, and 1TB HDD. What is the maximum limit of Swap memory that can be set in SSD?


title: How can I limit ssh *remote* port forwarding?

text: I need to limit which ports can be remotely '`ssh -R`' forwarded by an user. I know about `permitopen` option on authorized_keys, but as it says on man page it only limits local '`ssh -L`' port forwarding As discussed here an user would get the same with netcat or similar, but in this case user has no shell access I also found this thread that talks about using selinux or LD_PRELOAD, but I never configured selinux before and can't find info on how to do that with LD_PRELOAD. maybe someone have made a patch for openssh to implement that? EDIT: I've found this bug report so I guess it's not yet implemented


title: sshfs mount, sudo gets permission denied

text: I am using `sshfs` to mount a folder with some python projects over ssh to my `~/` directory.               $ mkdir -p ~/mount/myprojects     $ sshfs user@myserver:/home/user/myprojects ~/mount/myprojects      I can perform most commands as could be expected:               $ ls ~/mount/myprojects     somepythonproject      But I if I try to do anything with `sudo`, it fails with permission denied:               $ sudo ls ~/mount/myprojects     ls: cannot access /home/user/mount/myprojects: Permission denied      What I'm actually trying to accomplish is to test a python package installation script on my local machine:               $ cd ~/mount/myprojects/somepythonproject     $ sudo python setup.py install


title: CPU monitoring tool for Centos

text: I'm looking for a CPU monitoring tool that could monitor the different processors in my machine, and also has a GUI (similar to the Ubuntu monitoring tool). Is there anything like that in Centos?


title: show hostname in top

text: I'm using `top` with `tmux` to monitor the most-CPU-consuming processes on different computers. How can I get the hostname to be displayed in each pane? Can I tell `top` to display the hostname somehow? ![screenshot top+tmux](http://i.stack.imgur.com/QEYTO.png)


title: converting unix time to string time with date command

text: I have read the man pages for date command, but there is no option for converting unix time to string time. I found some websites telling this:               date -d @1343715322      there is no option like `@` in the man and info pages. Can someone explain it?


title: How to maximise a window horizontal or vertically?

text: In awesome, what key binding can you use to maximise a window (in floating mode, of course) so that it maximise in just the horizontal or just the vertical direction? I know that `mod4 + m` will maximise it fully in both directions so I kind of assume it will be possible to do a mapping to just one direction.


title: What happens to files in mountpoint after running fs-cifs to mount NAS?

text: I'm running QNX Neutrino. I've got some files in `/mountpoint`:               # ls /mountpoint     /mountpoint/a     /mountpoint/b      And after mounting my NAS using fs-cifs like so,               # fs-cifs //hostname:hostipaddress:/sharename /mountpoint login password &      I see the remote files (c, d) as well as my local files (a, b)               # ls /mountpoint     /mountpoint/a     /mountpoint/b     /mountpoint/c     /mountpoint/d      * * *   * Is this the expected behaviour? I thought `mount` usually hid the local files (as per Where do the files go if you mount a drive to a folder that already contains files?)   * Is there an easy way of determining whether the files listed are stored locally or on the NAS?   * Is there an easier method of moving local files in `/mountpoint` to the NAS than unmount, move local files to tmp, remount, move files from tmp to `/mountpoint`?


title: Vim NERDTree re-size vsplit

text: I am using the NERDTree plugin for Vim. When using the `s: open vsplit command`, is it possible to resize the windows so that the file takes up a larger portion of the screen than the directory tree?


title: How to get user-level access to modifier keypresses in console app?

text: I need to get access to modifier-key state for a console app I'm writing (a personalized editor). Are there any packages/libs/whatever that provide this access? I cobbled the following from somewhere, but it only works if you're root, and I don't really want to mess about at root-level.               #include <iostream>     #include <string>     #include <stdio.h>     #include <string.h>     #include <stdlib.h>     #include <termios.h>     #include <fcntl.h>     #include <linux/input.h>     #include <unistd.h>     #include <errno.h>          int kbhit(void)     {         struct termios oldt, newt;         int ch;         int oldf;              tcgetattr(STDIN_FILENO, &oldt);              newt = oldt;         newt.c_lflag &= ~0000172 ; //~(ICANON | ECHO);              tcsetattr(STDIN_FILENO, TCSANOW, &newt);         oldf = fcntl(STDIN_FILENO, F_GETFL, 0);         fcntl(STDIN_FILENO, F_SETFL, oldf | O_NONBLOCK);              ch = getchar();              tcsetattr(STDIN_FILENO, TCSANOW, &oldt);         fcntl(STDIN_FILENO, F_SETFL, oldf);              return ch;     }          enum MODKEYS     {         SHIFT_L = 1,         SHIFT_R = 2,         CTRL_L = 4,         CTRL_R = 8,         ALT_L = 16,         ALT_R = 32,     };          int chkmodifiers()     {         int mods=0,keyb,mask;         char key_map[KEY_MAX/8 + 1];    //  Create a byte array the size of the number of keys              //event1 - got by inspecting /dev/input/...          FILE *kbd = fopen("/dev/input/event1", "r");         if (kbd == NULL)         {             printf("(chkmodifiers) ERROR: %s\n", strerror(errno)); //permission - got to be root!             return 0;         }              memset(key_map, 0, sizeof(key_map));         ioctl(fileno(kbd), EVIOCGKEY(sizeof(key_map)), key_map);    //  Fill the keymap with the current keyboard state              keyb = key_map[KEY_LEFTSHIFT/8];         mask = 1 << (KEY_LEFTSHIFT % 8);         if (keyb & mask) mods += SHIFT_L;              keyb = key_map[KEY_RIGHTSHIFT/8];         mask = 1 << (KEY_RIGHTSHIFT % 8);         if (keyb & mask) mods += SHIFT_R;              keyb = key_map[KEY_LEFTCTRL/8];         mask = 1 << (KEY_LEFTCTRL % 8);         if (keyb & mask) mods += CTRL_L;              keyb = key_map[KEY_RIGHTCTRL/8];         mask = 1 << (KEY_RIGHTCTRL % 8);         if (keyb & mask) mods += CTRL_R;              keyb = key_map[KEY_LEFTALT/8];         mask = 1 << (KEY_LEFTALT % 8);         if (keyb & mask) mods += ALT_L;              keyb = key_map[KEY_RIGHTALT/8];         mask = 1 << (KEY_RIGHTALT % 8);         if (keyb & mask) mods += ALT_R;              return mods;          }               int main()     {         puts("Press a key!");              char ch=0;         int n=0,m;              while (ch != 'q')         {             n = kbhit();             if (n != -1)             {                 m = chkmodifiers();                 ch =  (char)n;                 printf("You pressed '%c' [%d]\n", ch, n);                 if ((m & SHIFT_L) == SHIFT_L) printf(" .. and ls\n");                 if ((m & SHIFT_R) == SHIFT_R) printf(" .. and rs\n");                 if ((m & CTRL_L) == CTRL_L) printf(" .. and lc\n");                 if ((m & CTRL_R) == CTRL_R) printf(" .. and rc\n");                 if ((m & ALT_L) == ALT_L) printf(" .. and la\n");                 if ((m & ALT_R) == ALT_R) printf(" .. and ra\n");                  }         }         return 0;     }


title: How can I find out how many lines a text file contains without viewing it?

text: How can I find how many lines a text file contains without opening the file in an editor or a viewer application? Is there a handy Unix console command to see the number?


title: Bash string replace multiple chars with one

text: I'm replacing, from a feed title, all chars except letters and digits with a dash to use the result as a safe filename for any filesystem:               $ t="Episodie 06: No hope of riding home (NEW) - Advanced grammar"     $ echo ${t//[^A-Za-z0-9]/-}     Episodie-06--No-hope-of-riding-home--NEW----Advanced-grammar      However I'd like to condense all repeating dashes with a single one like `Episodie-06-No-hope-of-riding-home-NEW-Advanced-grammar` I found I can achieve it using a two pass substitution:               $ t="Episodie 06: No hope of riding home (NEW) - Advanced grammar"     $ tmp=${t//[^A-Za-z0-9]/-}     $ echo ${tmp//--/-}     Episodie-06-No-hope-of-riding-home-NEW--Advanced-grammar      I thought I could do it in a single pass like:               $ echo ${t//[^A-Za-z0-9]+/-}      but it doesn't work. Any clue? Note: I don't want to go with `sed` or other tools


title: Monit won't execute commands

text: Running Monit 5.2.5 on Fedora 15 All standard alerts are working, however just cannot get **exec** to run anything. I have tried more than ten different configurations based on examples from the Monit Wiki. None of the **exec** commands do anything. Below is just one simple examples in an attempt to get 'something' working:               check process tomcat6 with pidfile /var/run/tomcat6.pid         start program = "/etc/init.d/tomcat6 start"         stop program = "/etc/init.d/tomcat6 stop"         if failed host localhost port 8080 then             exec "/bin/bash -c '/bin/touch /tmp/monittest'"      If I shutdown Tomcat an alert is sent and the service restarts. However whatever I try in **exec** is always ignored. I understand that Monit is very restrictive in terms of its environment and is limited to directories such as /bin and/sbin/. Therefore all the example I have tried have been restricted to these directories. But still nothing. Anyone any ideas? p.s. I have turned on verbose logging and no clues in the log file.


title: how to guess and rename file from deleted rar has invalid encoding

text: i have many files and folders that extracted from many rar from jdownloader, and deleted after extract, some of it names are:               �������[�ς݂��ς݂� - �Ȃ��ꂭ������ (invalid encoding)     �R�e���} (invalid encoding)     ??? - ? ??? ?      ���΂ɂ����� (invalid encoding)      i know that those name should be korean, chinese/taiwanese or japanese. and i know that we could convert those files using `convmv -f enc_from -t enc_to` but how to guess the current encoding of those files?


title: Installing and uninstalling gnome on debian

text: I am using debian sid with xfce. I would like to test last version of gnome (I didn't give gnome 3.x a chance). Therfore, I would like to install gnome _but_ , also, to know how to go back to my xfce desktop. My worries are to have hard time to uninstall all packages installed for gnome. I plan to install gnome with :               apt-get install gnome      Which produces:               The following extra packages will be installed:       accountsservice aglfn aisleriot alacarte apg argyll bluez bogofilter bogofilter-bdb       bogofilter-common browser-plugin-gnash caribou caribou-antler cheese cheese-common cli-common       cracklib-runtime dconf-cli dconf-editor dconf-tools empathy empathy-common eog espeak-data       evince evolution evolution-common evolution-data-server evolution-data-server-common       evolution-plugins file-roller finger five-or-more folks-common four-in-a-row gdebi gdm3 gedit       gedit-common gedit-plugins geoclue geoclue-hostip geoclue-localnet geoclue-manual       geoclue-nominatim gir1.2-accountsservice-1.0 gir1.2-atspi-2.0 gir1.2-caribou-1.0       gir1.2-clutter-gst-2.0 gir1.2-evince-3.0 gir1.2-gck-1 gir1.2-gconf-2.0 gir1.2-gcr-3       gir1.2-gdata-0.0 gir1.2-gdesktopenums-3.0 gir1.2-gdm3 gir1.2-gkbd-3.0 gir1.2-gmenu-3.0       gir1.2-gnomebluetooth-1.0 gir1.2-gnomedesktop-3.0 gir1.2-goa-1.0 gir1.2-gtkclutter-1.0       gir1.2-gtop-2.0 gir1.2-gucharmap-2.90 gir1.2-ibus-1.0 gir1.2-javascriptcoregtk-3.0       gir1.2-mutter-3.0 gir1.2-networkmanager-1.0 gir1.2-nmgtk-1.0 gir1.2-panelapplet-4.0       gir1.2-polkit-1.0 gir1.2-rb-3.0 gir1.2-rest-0.7 gir1.2-soup-2.4 gir1.2-telepathyglib-0.12       gir1.2-telepathylogger-0.2 gir1.2-totem-1.0 gir1.2-totem-plparser-1.0 gir1.2-tracker-0.16       gir1.2-upowerglib-1.0 gir1.2-vte-2.90 gir1.2-webkit-3.0 gir1.2-wnck-3.0 gir1.2-xkl-1.0       gir1.2-zpj-0.0 gjs gkbd-capplet gksu gnash gnash-common gnome-applets gnome-applets-data       gnome-backgrounds gnome-bluetooth gnome-calculator gnome-chess gnome-color-manager       gnome-contacts gnome-control-center gnome-control-center-data gnome-core gnome-desktop3-data       gnome-dictionary gnome-disk-utility gnome-documents gnome-font-viewer gnome-games       gnome-icon-theme-extras gnome-klotski gnome-mag gnome-mahjongg gnome-media gnome-menus       gnome-mines gnome-nettool gnome-nibbles gnome-online-accounts gnome-orca gnome-packagekit       gnome-packagekit-data gnome-packagekit-session gnome-panel gnome-panel-data gnome-power-manager       gnome-robots gnome-screensaver gnome-screenshot gnome-session gnome-session-bin       gnome-session-common gnome-session-flashback gnome-settings-daemon gnome-shell       gnome-shell-common gnome-shell-extensions gnome-sudoku gnome-sushi gnome-system-log       gnome-system-monitor gnome-terminal gnome-terminal-data gnome-tetravex gnome-tweak-tool       gnome-user-guide gnome-user-share gnome-video-effects gnuchess gnuchess-book gnuplot gnuplot-nox       gnustep-base-common gnustep-base-runtime gnustep-common grilo-plugins-0.2 groff       gstreamer0.10-nice gstreamer1.0-clutter gstreamer1.0-libav gstreamer1.0-nice       gstreamer1.0-plugins-bad gtk2-engines gucharmap guile-2.0-libs hamster-applet hwdata iagno       iputils-tracepath libaccountsservice0 libapache2-mod-dnssd libatk-adaptor libatspi1.0-0       libavahi-gobject0 libavahi-ui-gtk3-0 libavresample1 libboost-chrono1.54.0       libboost-program-options1.54.0 libboost-thread1.54.0 libbrlapi0.6 libcamel-1.2-43       libcanberra-gtk-module libcanberra-gtk0 libcanberra-pulse libcaribou-common       libcaribou-gtk-module libcaribou-gtk3-module libcaribou0 libchamplain-0.12-0       libchamplain-gtk-0.12-0 libcheese-gtk23 libcheese7 libclutter-gst-2.0-0 libclutter-gtk-1.0-0       libcolorblind0 libcolord-gtk1 libcpufreq0 libcrack2 libdbus-glib2.0-cil libdbus2.0-cil       libdee-1.0-4 libdmapsharing-3.0-2 libdotconf1.0 libebackend-1.2-6 libebook-1.2-14       libebook-contacts-1.2-0 libecal-1.2-15 libedata-book-1.2-17 libedata-cal-1.2-20       libedataserver-1.2-17 libespeak1 libevolution libexempi3 libfarstream-0.1-0 libfarstream-0.2-2       libfolks-eds25 libfolks-telepathy25 libfolks25 libgail-common libgconf2.0-cil libgdata-common       libgdata13 libgdict-1.0-6 libgdict-common libgdiplus libgdm1 libgeocode-glib0 libgksu2-0       libgles2-mesa libglib2.0-cil libgnome-desktop-3-7 libgnome-mag2 libgnome-media-profiles-3.0-0       libgnome-menu-3-0 libgnomekbd-common libgnomekbd8 libgnustep-base1.22 libgrilo-0.2-1       libgsf-1-114 libgsf-1-common libgssdp-1.0-3 libgstreamer-plugins-bad1.0-0 libgtk-vnc-2.0-0       libgtk2.0-cil libgtkglext1 libgtkhtml-4.0-0 libgtkhtml-4.0-common libgtkhtml-editor-4.0-0       libgtkmm-3.0-1 libgtop2-7 libgtop2-common libgucharmap-2-90-7 libgupnp-1.0-4 libgupnp-av-1.0-2       libgupnp-dlna-2.0-3 libgupnp-igd-1.0-4 libgvnc-1.0-0 libgweather-3-3 libgweather-common       libibus-1.0-5 libicc2 libidl0 libimdi0 libiptcdata0 libjemalloc1 liblinear-tools liblinear1       liblouis-data liblouis2 libmeanwhile1 libmetacity-private0a libmission-control-plugins0       libmono-addins-gui0.2-cil libmono-addins0.2-cil libmono-cairo4.0-cil libmono-corlib4.0-cil       libmono-corlib4.5-cil libmono-i18n-west4.0-cil libmono-i18n4.0-cil libmono-posix4.0-cil       libmono-security4.0-cil libmono-sharpzip4.84-cil libmono-system-configuration4.0-cil       libmono-system-core4.0-cil libmono-system-drawing4.0-cil libmono-system-security4.0-cil       libmono-system-xml4.0-cil libmono-system4.0-cil libmpg123-0 libmusicbrainz5-0 libmutter0b       libnatpmp1 libnice10 liboauth0 libobjc4 libopencv-calib3d2.4 libopencv-contrib2.4       libopencv-core2.4 libopencv-features2d2.4 libopencv-flann2.4 libopencv-highgui2.4       libopencv-imgproc2.4 libopencv-legacy2.4 libopencv-ml2.4 libopencv-objdetect2.4       libopencv-video2.4 libopenobex1 liborbit2 libpam-systemd libpanel-applet-4-0 libpst4       libpulse-mainloop-glib0 libpulsedsp libpurple-bin libpurple0 libpwquality-common libpwquality1       libreoffice-gnome librest-extras-0.7-0 librhythmbox-core8 librygel-core-2.0-1       librygel-renderer-2.0-1 librygel-renderer-gst-2.0-1 librygel-server-2.0-1 libsbc1       libsocialweb-client2 libsocialweb-common libsocialweb-service libsocialweb0       libsofia-sip-ua-glib3 libsofia-sip-ua0 libsonic0 libsrtp0 libsvm-tools libsystemd-daemon0       libtbb2 libtelepathy-farstream3 libtelepathy-glib0 libtelepathy-logger3 libtotem0       libtracker-extract-0.16-0 libtracker-miner-0.16-0 libwacom-common libwacom2       libwebrtc-audio-processing-0 libwnck-3-0 libwnck-3-common libytnef0 libzapojit-0.0-0       libzeitgeist-1.0-1 libzeitgeist-2.0-0 libzephyr4 lightsoff media-player-info metacity       metacity-common mono-4.0-gac mono-gac mono-runtime mousetweaks mutter-common nautilus       nautilus-data nautilus-sendto nautilus-sendto-empathy nmap obex-data-server obexd-client       pidgin-data pulseaudio pulseaudio-module-x11 pulseaudio-utils python-brlapi python-gconf       python-gnome2 python-louis python-mako python-markupsafe python-pyatspi python-pyatspi2       python-pyorbit python-speechd python-wnck python-zeitgeist quadrapassel rdesktop rhythmbox       rhythmbox-data rhythmbox-plugin-cdrecorder rhythmbox-plugins rtkit rygel rygel-playbin       rygel-preferences simple-scan sound-juicer sound-theme-freedesktop speech-dispatcher sudo       swell-foop systemd tali telepathy-gabble telepathy-haze telepathy-idle telepathy-logger       telepathy-mission-control-5 telepathy-rakia telepathy-salut tomboy totem totem-common       totem-plugins tracker tracker-extract tracker-gui tracker-miner-fs tracker-utils       transmission-common transmission-gtk unar unoconv vinagre vino xbrlapi xdg-user-dirs-gtk       xserver-xephyr xul-ext-adblock-plus zeitgeist zeitgeist-core zeitgeist-datahub zenity       zenity-common     Suggested packages:       gnome-cards-data gir1.2-colordgtk-1.0 doc-base browser-plugin-lightspark       gnome-video-effects-frei0r evolution-ews evolution-plugins-experimental       evolution-data-server-dbg arj lha lzip lzop ncompress rpm2cpio rzip sharutils unace unalz zoo       dia-gnome gnome-boxes gnucash libreoffice-evolution planner iceweasel-l10n-all       xul-ext-gnome-keyring libcanberra-gtk3-module gnome-hearts gnome-system-tools       gnome-packagekit-tools xboard eboard scid feedgnuplot gnuplot-doc libgnuplot-iostream-dev       python-gnuplot gnustep-base-doc frei0r-plugins python-evolution monodoc-gtk2.0-manual       liblinear-dev libmono-i18n4.0-all libgamin0 natpmp-utils sofia-sip-doc srtp-utils pidgin gajim       pavumeter pavucontrol paman paprefs python-gnome2-doc python-beaker python-mako-doc pcscd       gnome-codec-install rygel-tracker rygel-mediathek gstreamer0.10-plugins-ugly gstreamer0.10-lame       gstreamer0.10-plugins-really-bad speech-dispatcher-festival speech-dispatcher-doc-cs       libttspico-utils systemd-ui tasque totem-mozilla gromit     The following packages will be REMOVED:       evince-gtk     The following NEW packages will be installed:       accountsservice aglfn aisleriot alacarte apg argyll bluez bogofilter bogofilter-bdb       bogofilter-common browser-plugin-gnash caribou caribou-antler cheese cheese-common cli-common       cracklib-runtime dconf-cli dconf-editor dconf-tools empathy empathy-common eog espeak-data       evince evolution evolution-common evolution-data-server evolution-data-server-common       evolution-plugins file-roller finger five-or-more folks-common four-in-a-row gdebi gdm3 gedit       gedit-common gedit-plugins geoclue geoclue-hostip geoclue-localnet geoclue-manual       geoclue-nominatim gir1.2-accountsservice-1.0 gir1.2-atspi-2.0 gir1.2-caribou-1.0       gir1.2-clutter-gst-2.0 gir1.2-evince-3.0 gir1.2-gck-1 gir1.2-gconf-2.0 gir1.2-gcr-3       gir1.2-gdata-0.0 gir1.2-gdesktopenums-3.0 gir1.2-gdm3 gir1.2-gkbd-3.0 gir1.2-gmenu-3.0       gir1.2-gnomebluetooth-1.0 gir1.2-gnomedesktop-3.0 gir1.2-goa-1.0 gir1.2-gtkclutter-1.0       gir1.2-gtop-2.0 gir1.2-gucharmap-2.90 gir1.2-ibus-1.0 gir1.2-javascriptcoregtk-3.0       gir1.2-mutter-3.0 gir1.2-networkmanager-1.0 gir1.2-nmgtk-1.0 gir1.2-panelapplet-4.0       gir1.2-polkit-1.0 gir1.2-rb-3.0 gir1.2-rest-0.7 gir1.2-soup-2.4 gir1.2-telepathyglib-0.12       gir1.2-telepathylogger-0.2 gir1.2-totem-1.0 gir1.2-totem-plparser-1.0 gir1.2-tracker-0.16       gir1.2-upowerglib-1.0 gir1.2-vte-2.90 gir1.2-webkit-3.0 gir1.2-wnck-3.0 gir1.2-xkl-1.0       gir1.2-zpj-0.0 gjs gkbd-capplet gksu gnash gnash-common gnome gnome-applets gnome-applets-data       gnome-backgrounds gnome-bluetooth gnome-calculator gnome-chess gnome-color-manager       gnome-contacts gnome-control-center gnome-control-center-data gnome-core gnome-desktop3-data       gnome-dictionary gnome-disk-utility gnome-documents gnome-font-viewer gnome-games       gnome-icon-theme-extras gnome-klotski gnome-mag gnome-mahjongg gnome-media gnome-menus       gnome-mines gnome-nettool gnome-nibbles gnome-online-accounts gnome-orca gnome-packagekit       gnome-packagekit-data gnome-packagekit-session gnome-panel gnome-panel-data gnome-power-manager       gnome-robots gnome-screensaver gnome-screenshot gnome-session gnome-session-bin       gnome-session-common gnome-session-flashback gnome-settings-daemon gnome-shell       gnome-shell-common gnome-shell-extensions gnome-sudoku gnome-sushi gnome-system-log       gnome-system-monitor gnome-terminal gnome-terminal-data gnome-tetravex gnome-tweak-tool       gnome-user-guide gnome-user-share gnome-video-effects gnuchess gnuchess-book gnuplot gnuplot-nox       gnustep-base-common gnustep-base-runtime gnustep-common grilo-plugins-0.2 groff       gstreamer0.10-nice gstreamer1.0-clutter gstreamer1.0-libav gstreamer1.0-nice       gstreamer1.0-plugins-bad gtk2-engines gucharmap guile-2.0-libs hamster-applet hwdata iagno       iputils-tracepath libaccountsservice0 libapache2-mod-dnssd libatk-adaptor libatspi1.0-0       libavahi-gobject0 libavahi-ui-gtk3-0 libavresample1 libboost-chrono1.54.0       libboost-program-options1.54.0 libboost-thread1.54.0 libbrlapi0.6 libcamel-1.2-43       libcanberra-gtk-module libcanberra-gtk0 libcanberra-pulse libcaribou-common       libcaribou-gtk-module libcaribou-gtk3-module libcaribou0 libchamplain-0.12-0       libchamplain-gtk-0.12-0 libcheese-gtk23 libcheese7 libclutter-gst-2.0-0 libclutter-gtk-1.0-0       libcolorblind0 libcolord-gtk1 libcpufreq0 libcrack2 libdbus-glib2.0-cil libdbus2.0-cil       libdee-1.0-4 libdmapsharing-3.0-2 libdotconf1.0 libebackend-1.2-6 libebook-1.2-14       libebook-contacts-1.2-0 libecal-1.2-15 libedata-book-1.2-17 libedata-cal-1.2-20       libedataserver-1.2-17 libespeak1 libevolution libexempi3 libfarstream-0.1-0 libfarstream-0.2-2       libfolks-eds25 libfolks-telepathy25 libfolks25 libgail-common libgconf2.0-cil libgdata-common       libgdata13 libgdict-1.0-6 libgdict-common libgdiplus libgdm1 libgeocode-glib0 libgksu2-0       libgles2-mesa libglib2.0-cil libgnome-desktop-3-7 libgnome-mag2 libgnome-media-profiles-3.0-0       libgnome-menu-3-0 libgnomekbd-common libgnomekbd8 libgnustep-base1.22 libgrilo-0.2-1       libgsf-1-114 libgsf-1-common libgssdp-1.0-3 libgstreamer-plugins-bad1.0-0 libgtk-vnc-2.0-0       libgtk2.0-cil libgtkglext1 libgtkhtml-4.0-0 libgtkhtml-4.0-common libgtkhtml-editor-4.0-0       libgtkmm-3.0-1 libgtop2-7 libgtop2-common libgucharmap-2-90-7 libgupnp-1.0-4 libgupnp-av-1.0-2       libgupnp-dlna-2.0-3 libgupnp-igd-1.0-4 libgvnc-1.0-0 libgweather-3-3 libgweather-common       libibus-1.0-5 libicc2 libidl0 libimdi0 libiptcdata0 libjemalloc1 liblinear-tools liblinear1       liblouis-data liblouis2 libmeanwhile1 libmetacity-private0a libmission-control-plugins0       libmono-addins-gui0.2-cil libmono-addins0.2-cil libmono-cairo4.0-cil libmono-corlib4.0-cil       libmono-corlib4.5-cil libmono-i18n-west4.0-cil libmono-i18n4.0-cil libmono-posix4.0-cil       libmono-security4.0-cil libmono-sharpzip4.84-cil libmono-system-configuration4.0-cil       libmono-system-core4.0-cil libmono-system-drawing4.0-cil libmono-system-security4.0-cil       libmono-system-xml4.0-cil libmono-system4.0-cil libmpg123-0 libmusicbrainz5-0 libmutter0b       libnatpmp1 libnice10 liboauth0 libobjc4 libopencv-calib3d2.4 libopencv-contrib2.4       libopencv-core2.4 libopencv-features2d2.4 libopencv-flann2.4 libopencv-highgui2.4       libopencv-imgproc2.4 libopencv-legacy2.4 libopencv-ml2.4 libopencv-objdetect2.4       libopencv-video2.4 libopenobex1 liborbit2 libpam-systemd libpanel-applet-4-0 libpst4       libpulse-mainloop-glib0 libpulsedsp libpurple-bin libpurple0 libpwquality-common libpwquality1       libreoffice-gnome librest-extras-0.7-0 librhythmbox-core8 librygel-core-2.0-1       librygel-renderer-2.0-1 librygel-renderer-gst-2.0-1 librygel-server-2.0-1 libsbc1       libsocialweb-client2 libsocialweb-common libsocialweb-service libsocialweb0       libsofia-sip-ua-glib3 libsofia-sip-ua0 libsonic0 libsrtp0 libsvm-tools libsystemd-daemon0       libtbb2 libtelepathy-farstream3 libtelepathy-glib0 libtelepathy-logger3 libtotem0       libtracker-extract-0.16-0 libtracker-miner-0.16-0 libwacom-common libwacom2       libwebrtc-audio-processing-0 libwnck-3-0 libwnck-3-common libytnef0 libzapojit-0.0-0       libzeitgeist-1.0-1 libzeitgeist-2.0-0 libzephyr4 lightsoff media-player-info metacity       metacity-common mono-4.0-gac mono-gac mono-runtime mousetweaks mutter-common nautilus       nautilus-data nautilus-sendto nautilus-sendto-empathy nmap obex-data-server obexd-client       pidgin-data pulseaudio pulseaudio-module-x11 pulseaudio-utils python-brlapi python-gconf       python-gnome2 python-louis python-mako python-markupsafe python-pyatspi python-pyatspi2       python-pyorbit python-speechd python-wnck python-zeitgeist quadrapassel rdesktop rhythmbox       rhythmbox-data rhythmbox-plugin-cdrecorder rhythmbox-plugins rtkit rygel rygel-playbin       rygel-preferences simple-scan sound-juicer sound-theme-freedesktop speech-dispatcher sudo       swell-foop systemd tali telepathy-gabble telepathy-haze telepathy-idle telepathy-logger       telepathy-mission-control-5 telepathy-rakia telepathy-salut tomboy totem totem-common       totem-plugins tracker tracker-extract tracker-gui tracker-miner-fs tracker-utils       transmission-common transmission-gtk unar unoconv vinagre vino xbrlapi xdg-user-dirs-gtk       xserver-xephyr xul-ext-adblock-plus zeitgeist zeitgeist-core zeitgeist-datahub zenity       zenity-common     0 upgraded, 432 newly installed, 1 to remove and 0 not upgraded.     Need to get 0 B/259 MB of archives.     After this operation, 891 MB of additional disk space will be used.     Do you want to continue? [Y/n] n     Abort.      So there are lots of packages... I would like to be sure to be able to uninstall all these packages after trying gnome for some time. I'm afraid `apt-get remove --purge gnome` will not remove all previously installed packages (because gnome is a meta-package). So, what should I do, after installing gnome, to go back on my minimal xfce system (i.e. delete all installed gnome related packages)? Update : `apt-get autoremove` does not remove any of the package installed automatically by gnome. I deleted the gnome meta-package:                # apt-get remove gnome     Reading package lists... Done     Building dependency tree            Reading state information... Done     The following packages will be REMOVED:       gnome     0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.     After this operation, 53.2 kB disk space will be freed.     Do you want to continue? [Y/n] y      And then tried to remove all gnome packages with `autoremove`               # apt-get autoremove     Reading package lists... Done     Building dependency tree            Reading state information... Done     0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.


title: How to open a GNOME 3 window from console?

text: in my GNOME 2 ubuntu i used to issue this command to open a new window to browse the files in some folder:               nautilus ./      For example, i could go to a difficult location through the console, and when i found it I opened the window:               cd /home/santiago/Music/Blues/BB-King/Live/Live at...     nautilus ./      And that folder was displayed in the window, and i could browse it regulary. But now I have GNOME 3 on Fedora 15 and that doesn't work any more. I think it's becouse the process doesn't return control to the console, so if i want to do that different times, the subsequents calls to `nautilus ./` open the first location. Thank you!


title: rpm --upgrade not upgrading?

text: Can someone please help me understand the rpm command. From the rpm man pages:               rpm {-U|--upgrade} [install-options] PACKAGE_FILE ...          This upgrades or installs the package currently installed to a newer version.     This is the same as install, except all other version(s) of the package are     removed after the new package is installed.      My understanding is that if I indicate a `PACKAGE_FILE` that is an upgrade of something I already have installed, it will replace the files... upgrading the package. Specifically I am trying to upgrade _VirtualBox_ on a _Fedora 14_ OS. I am running the following command:               rpm -Uvh VirtualBox-4.1-4.1.4_74291_fedora14-1.x86_64.rpm      and am getting (many) errors saying there is an older version of the file               ... <similar output omitted>          file /bla/virtualbox/bla/powernotification-r0drv.c from install of        VirtualBox-4.1-4.1.4_74291_fedora14-1.x86_64 conflicts with file from         package VirtualBox-4.0-4.0.12_72916_fedora14-1.x86_64          ... </similar output omitted>      I am obviously not understanding something here. Can anyone shed some light on this?


title: Rename current file in vim

text: Searching over net shows `:f filename` would rename the current file in `vim`. But executing this and later exiting `vim`, shows the new file with all the contents and also the old file is present with the saved content untill executing the above command. So, how can we rename the current file we are editing in `vim` ? **EDIT** - Any solution that does not involve a plugin, as I guess that would require administrative privileges which I don't have. Any tweaks with config or mapping ?


title: Mount a Rackspace drive in Linux

text: Is there any software that will allow me to mount a Rackspace drive in linux? I want to copy SQL files from my database onto my Rackspace. I have web min running a backup nightly and copying those backups offsite would be ideal for obvious reasons. On my Windows desktop I've been using Cyberduck to upload/download and manage files on the server. I purchased a subscription to "Jungle Disk" but this problem was unstable on all the systems I had available in my office — Ubuntu and Windows 7. The application itself seems alright but any click took on average 10 seconds to respond. Can anyone point me in the right direction to the most simple way to copy this stuff to Rackspace? I have a Cloud Files account and am using Ubuntu.


title: How do I stop gnome's disk-utility from spamming me with disk error messages until my X session freezes?

text: I have a headless computer running ubuntu 11.04 with metacity. I vnc into it every now and again. It has a failing disk attached which I am trying to get some data off. Every now and again a friendly message comes up titled "Disk Utility" saying "Hard disk problems detected" and giving me the option to "Examine", "Ok" or "Cancel" (cool, did not know I could just cancel my hard disk problems). This is useful the first time but it comes up a lot. So often in fact that the next morning my X session has usually been rendered unusable because so many of these dialog windows have popped up. I don't really consider this a usability win. How can I disable it?