title: unable to back-up data from android tablet to laptop using tar!

text: I'm using `tar` to back-up data from my android tablet to laptop. But it is showing some error.               ravbholua@ravbholua-Aspire-5315:/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/9$ tar -cvf /media/ravbholua/f34890dd-20d2-4d78-92c9-1de7c0957f00/jackal.tar .     ./     tar: ./33: Cannot open: Operation not supported     tar: ./34: Cannot open: Operation not supported     tar: ./35: Cannot open: Operation not supported     tar: ./36: Cannot open: Operation not supported     tar: ./37: Cannot open: Operation not supported     tar: ./38: Cannot open: Operation not supported     ./50/     ./50/62/     tar: ./50/209: Cannot open: Operation not supported     tar: ./50/210: Cannot open: Operation not supported     tar: ./50/211: Cannot open: Operation not supported     tar: ./50/216: Cannot open: Operation not supported     tar: ./50/217: Cannot open: Operation not supported     tar: ./50/218: Cannot open: Operation not supported     ./50/236/     ./50/249/     tar: ./50/903: Cannot open: Operation not supported     tar: ./50/904: Cannot open: Operation not supported     tar: ./50/905: Cannot open: Operation not supported     tar: ./50/906: Cannot open: Operation not supported     tar: ./50/907: Cannot open: Operation not supported          ravbholua@ravbholua-Aspire-5315:/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/9$ sudo tar -cvf /media/ravbholua/f34890dd-20d2-4d78-92c9-1de7c0957f00/jackal.tar .     [sudo] password for ravbholua:      tar: .: Cannot stat: Permission denied     tar: Exiting with failure status due to previous errors      (I'm unable to take back-up from nautilus even as clear from this thread) (I would like to add that the file names aren't displayed clearly in my laptop for the android files in the terminal. I've this thread regarding this.) ### EDIT I used `rsync` command but the same error.               ravbholua@ravbholua-Aspire-5315:/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50$ rsync -avz ./ ~/Dow*     sending incremental file list     ./     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1078": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1079": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1080": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1081": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1082": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1083": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1085": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1086": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1087": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1088": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1089": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1090": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1091": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1094": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1103": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1154": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1155": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1156": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1157": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1158": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1159": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1160": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1161": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1162": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1171": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1172": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1278": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1279": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1280": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1282": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1283": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1284": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1285": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1286": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1287": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1397": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1398": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1399": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1400": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1401": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1402": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1403": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1404": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1405": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1406": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1407": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1408": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1409": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1501": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1512": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1635": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1645": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1646": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1647": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1650": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1655": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1656": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1657": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1660": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1661": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1662": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1663": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1664": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1665": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1666": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1667": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1668": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1669": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1670": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1671": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1675": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1676": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/209": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/210": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/211": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/216": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/217": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/218": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/2841": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/2842": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/2849": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/2850": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/2851": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/3118": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/903": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/904": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/905": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/906": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/907": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/910": Operation not supported (95)     1096/     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1096/1102": Operation not supported (95)     1636/     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1637": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1638": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1639": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1640": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1641": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1642": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1643": Operation not supported (95)     rsync: send_files failed to open "/run/user/ravbholua/gvfs/mtp:host=%5Busb%3A002%2C003%5D/65537/50/1636/1644": Operation not supported (95)     236/     249/     62/          sent 2096 bytes  received 1916 bytes  2674.67 bytes/sec     total size is 2364535131  speedup is 589365.69     rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1070) [sender=3.0.9]


title: What is the best way to find directories that exactly match a string irrespective of the path?

text: Suppose I have the directories:               /foo/     /A/B/C/foo/D/E/     /F/foo/G/H/foo/I/      How can get a result that lists all the directories whose basename exactly matches a given string (for example `foo` in here)?               /foo/     /A/B/C/foo/     /F/foo/     /F/foo/G/H/foo/


title: Web access through a remote proxy accessed over SSH

text: I'm browsing the web on a client PC running Windows or Linux. I want to browse a website (`http://access.lan:52050//cgi-bin/login.cgi`) which is not directly accessible from my PC.   * I can browse the website if I go through a proxy machine. Its IP address is 192.168.1.1. It's running Red Hat Linux.   * I can log in to the Red Hat machine from my client PC with SSH version 1. How can I set this up in a simple way?


title: How can I reduce a video's size with ffmpeg?

text: How can I use `ffmpeg` to reduce the size of a video by lowering the quality (as minimally as possible, naturally, but I need it to run on a mobile device that doesn't have much available space)? I forgot to write one thing yet. When the video can use subtitles (*.srt or *.sub) I'd like to convert them too to fit the parameters of converted video file.


title: How to totally fork a shell command that is using redirection

text: I've written quite a few shell scripts over the years (but I'm certainly not a sysadmin) and there's something that always caused me troubles: how can I fork a shell command immune to hangups in the background from a _Bash_ script? For example if I have this:               command_which_takes_time input > output      How can I "nohup" and fork this? The following doesn't seem to do what I want:               nohup command_which_takes_time input > output &      What is the syntax I am looking for and what am I not understanding?


title: What is Fedora's equivalent of 'apt-get purge'?

text: In Debian, there's at least two ways to delete a package:   * `apt-get remove pkgname`   * `apt-get purge pkgname` The first preserves system-wide config files (i.e. those found in " **/etc** "), while the second doesn't. What is Fedora's equivalent of the second form, `purge`? Or maybe I should rather ask if `yum remove pkgname` actually preserves config files.


title: Resizing logical volume with no free extents but with free disk space

text: I have a 7.9 TB logical volume formatted with XFS filesystem. I have 8 1 TB RAID devices as physical volumes, and 1 volume group that contains all of these devices. I have 2.5 TB free space on my logical volume. I'd like to remove 2 of the 1 TB devices from the volume group since I don't "need" them anymore. Reading the man page of pvmove, it seems like I would need to create at least 5.5 TB of space and pvmove everything from the current 1 TB volumes onto the new volumes, and then remove all 8 of the original volumes from the logical volume. This seems onerous. Any suggestions?


title: How does one make x-screensavers work with mate-screensaver?

text: I am currently using Linux Mint - Mate Edition. I much prefer the mate- screensaver lock-screen so I refuse to use x-screensaver b/c its lock-screen is just hideous. I have learned elsewhere on the internet that one can use x-screensavers on mate-screensaver merely by editing the .desktop files. However, the image manipulating ones do not work b/c the x-screensaver daemon normally takes a screenshot of the active desktop and then hands it to the screensaver to use and therefore this does not work when using such screen-savers with the mate- screensaver. How can I make them work properly? (by taking a screenshot first and then using it)


title: Laptop running ~30° hotter than normal; CPU/Load is reportedly normal. What could cause this and how can I diagnose it?

text: I'm running the latest Arch Linux on my ThinkPad t420 laptop, and am having an intermittent heat problem where my temp will rise from the typical ~45°C to ~75-90°C, and stay there until I reboot. I've run several diagnostic tools, including the obvious `htop` and others that googling has suggested, including `powertop`, `iostats`, and surely others I don't recall. So far I've come up with no obvious issues, and ostensibly no differences in readouts whether my machine is running normally or in this hot state. I've also killed most suspicious processes one by one (databases and other daemons), hoping to find the hidden culprit, to no avail. Beyond these attempts, **I don't know where to begin troubleshooting**. I'm hoping someone could point me in the right direction to begin looking for the deeper issue. ### To be precise, my question is not how to cool my machine, but rather what could cause a consistent 30+ degree heat change in a system where (reportedly) CPU and load is normal? And what tools/practices could I use to diagnose it? Some notes that might be helpful:   * I **can** cool the system (e.g. by disengaging the fan control completely), but it immediately heats up again if left alone. This seems to suggest that heat retention is not an issue, but rather _something_ is continually generating heat.   * CPU usage and load are reported by `htop` as normal after entering this hot state. This includes kernel threads. According to `htop`, the system is essentially idle (1-2% sytem wide CPU usage, a load of 0.10).   * My machine uses Intel HD integrated graphics, and _has no other graphics card_. An nVidia card was an option for this model, as noted by @braiam; I did not opt for it.   * @terdon brought up the CPU governor settings. My CPUs are set to `powersave`   * My specific processor is a 2.7GHz Core i7-2620M. **Edit** : At the time of writing this question, my fancontrol was not functioning properly and ran continually at a middle RPM range (3900 RPMs), even at high temps. At the suggestion of @Alex and @JustDanyul, this has been fixed. The underlying problem, however, still remains.


I'm trying to set up automatic SSH hopping through a server which doesn't have nc. This works from the command line:               ssh -A gateway ssh steve@target      (I have added my public key to the SSH agent). However, adding it to ~/.ssh/config doesn't:               Host target       User steveb       ProxyCommand ssh -A gateway ssh steve@targetip          $ ssh target     Pseudo-terminal will not be allocated because stdin is not a terminal.               ^CKilled by signal 2.      Attempting to force the issue with `-t` is amusing but unhelpful.               ProxyCommand ssh -A -t gateway ssh steve@targetip          $ ssh target     Pseudo-terminal will not be allocated because stdin is not a terminal.     Pseudo-terminal will not be allocated because stdin is not a terminal.               ^CKilled by signal 2.      More `-t`'s? No good.               ProxyCommand ssh -A -t -t gateway ssh steve@targetip          $ ssh target     tcgetattr: Inappropriate ioctl for device               ^CKilled by signal 2.      Is this possible? Most tutorials (eg http://www.arrfab.net/blog/?p=246 ) suggest using `nc`.


title: i want to save the result of one command in a file

text: I am using cppcheck tool to analyze source code. At the shell prompt in gcc compiler, I have given the command as follows               $ cppcheck abc.cpp        The output is               checking abc.cpp...        (error) Possible null pointer dereference: <var> - otherwise it is redundant to check if   <var> is null at line 100         segmentation fault      I want this output to be saved in a file, so I have given the command as follows               $ cppcheck abc.cpp 2> abc.txt      But the contents of abc.txt file is as follows               checking abc.cpp...        It is only saving the first line, the main error part is missing in abc.txt file. Which command should I use to get all the output lines in a file? The manual of cppcheck tool is here.


title: apt-get -f install is stuck on "corrupted filesystem tarfile"

text: I am having issues with `apt-get` on my _Raspberry Pi_. This is the output when I try and install a package:               pi@raspberrypi ~ $ sudo apt-get -f install cowsay     Reading package lists... Done     Building dependency tree     Reading state information... Done     You might want to run 'apt-get -f install' to correct these:     The following packages have unmet dependencies:      emacs23 : Depends: libm17n-0 (>= 1.6.1) but it is not going to be installed     E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).      `sudo apt-get -f install` didn't help:               sudo apt-get -f install     Reading package lists... Done     Building dependency tree     Reading state information... Done     Correcting dependencies... Done     The following extra packages will be installed:       libm17n-0     Suggested packages:       m17n-docs     The following NEW packages will be installed:       libm17n-0     0 upgraded, 1 newly installed, 0 to remove and 4 not upgraded.     12 not fully installed or removed.     Need to get 0 B/258 kB of archives.     After this operation, 837 kB of additional disk space will be used.     Do you want to continue [Y/n]? y     Use of uninitialized value $value in substitution (s///) at /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line 515.     (Reading database ... 58096 files and directories currently installed.)     Unpacking libm17n-0 (from .../libm17n-0_1.6.3-2_armhf.deb) ...     dpkg: error processing /var/cache/apt/archives/libm17n-0_1.6.3-2_armhf.deb (--unpack):      corrupted filesystem tarfile - corrupted package archive     dpkg-deb (subprocess): decompressing archive member: internal gzip read error: '<fd:4>: invalid distance too far back'     dpkg-deb: error: subprocess <decompress> returned error exit status 2     Errors were encountered while processing:      /var/cache/apt/archives/libm17n-0_1.6.3-2_armhf.deb     E: Sub-process /usr/bin/dpkg returned an error code (1)      Any suggestion on how this issue can be resolved, beside reflashing the SD and starting again?


title: Delete extraneous files from dest dir via rsync?

text: Say I have               SRC        001.jpg       002.jpg       001.txt       a.zip          DEST       hello.jpg      `rsync -d --delete SRC:{*.jpg,*.txt} DEST` It doesn't remove hello.jpg from DEST, any idea how to archive this?


title: Relationship of keyboard layout and xmodmap

text: I'm using Xubuntu. Before login I can choose a keyboard layout. I'm using `xmodmap` for remmaping some keys. I'm interested in two things:   1. How the state of keyboard mapping changes when I turn the laptop on, during the boot process and login to the system (in these three phases) and when working with the system (logged in).   2. What causes which symbols will be displayed on the screen (and control keys sent) during the individual phases. When I press some key, it sends some signal to the keyboard driver(?) and then there must be some decision process (applications and configuration files) determining what symbols will be displayed. Answer to this question should be the list of applications and paths to those configuration files (I'm especially interested in Ubuntu (Debian based system), but you can describe some other system, but Ubuntu is preferred).


title: How to use Filetype in Vim?

text: In most cases, I want to use tabstop=4 while editing files. But for some types of file, like xml file, I want to use tabstop=2. I added > au filetypedetect FileType xml,html,xhtml,javascript set tabstop=2 > softtabstop=2 shiftwidth=2 in my .vimrc file. It works if I am editing only one file. But if I am editing multiple files, it cannot set the tab stops correctly for all the buffers. It seems the file type is detected and set only on startup, and never change since. I want the FileType set each time I switch the buffer, how can I do that?


title: Jump to start of the line in Bash's Vi mode

text: I'm using Bash Vi mode (aka `set -o vi`). Still I miss the `Ctrl-A` shortcut from Emacs mode, which is very handy. Many times I'm retrieving the last command and append an echo to the beginning of the line in order to save it to a file. Is there a convenient way to jump to the start of the line while in insert mode? And by convenient I mean that it's accessible by two sensible buttons shortcut. So `Esc,I` is not good enough, because `Esc` is too far, and `Ctrl+[`,`I` is not good because I need to type three consecutive letters, not sleek enough.


title: Multiple X startup profiles

text: I run XMonad window manager and use .XSession to startup things like Dropbox and launch other apps I need, at login manager i select User Defined Session. I like to know is there a login manager where I can have .XSession1, .XSession2 and .XSession3 where I have different profiles. So 1st one 'daily dev', 'just browsing' and thirdly 'offline' ?


title: What are the advantages of building tools/libs from source?

text: By building from source do you gain any benefits? Is the code better optimized to your hardware architecture? Is it optimized better in general? Why would someone choose to build from source rather than using a package management system like APT/yum? If there is some kind of optimization gain when does that outweigh the benefit of a package management system?


title: Why can't I upgrade Linux Mint 15 from Cinnamon 1.8.8 to Cinnamon 2.0, and how do I fix it?

text: So Cinnamon 2.0 is out, and I've followed the steps people have given for upgrading.               sudo add-apt-repository ppa:gwendal-lebihan-dev/cinnamon-stable      sudo apt-get update     sudo apt-get dist-upgrade      This however doesn't work. It says I'm already on the newest version. I've tried doing this from a different DE, but that also didn't work. I don't appear to have any held packages in apt, so that's not the problem. Do I need to uninstall Cinnamon and reinstall it? Is there something I'm missing? Thanks.


title: avconv stops streaming after some time

text: I am using raspberry-pi board and a usb camera attached with it. i use avconv tool to capture live video from camera and streaming it on network using rtp protocol. My command on server(raspberry-pi board) is as below: **avconv -f video4linux2 -s 160x120 -i /dev/video0 -vcodec mpeg2video -r 25 -pix_fmt yuv420p -me_method epzs -b 2600k -bt 256k -f rtp rtp://192.168.1.141:8554** streaming works successfully using this command. Here IP address 192.168.1.141 is the ip address of my client pc. i can play live streaming on client side using vlc successfully. But Issue is after some time encoding and streaming on server stop automatically. And command hangs there. Output on server is as below:               $ avconv -f video4linux2 -s 160x120 -v debug -i /dev/video0 -vcodec mpeg2video -r 25 -pix_fmt yuv420p -me_method epzs -b 2600k -bt 256k -f rtp rtp://192.168.1.141:8554     avconv version 0.8.10-6:0.8.10-1+rpi1, Copyright (c) 2000-2013 the Libav developers       built on Mar 22 2014 02:13:15 with gcc 4.6.3       configuration: --arch=arm --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.10-1+rpi1' --libdir=/usr/lib/arm-linux-gnueabihf --prefix=/usr --disable-yasm --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/arm-linux-gnueabihf --enable-shared --disable-static       libavutil    51. 22. 2 / 51. 22. 2       libavcodec   53. 35. 0 / 53. 35. 0       libavformat  53. 21. 1 / 53. 21. 1       libavdevice  53.  2. 0 / 53.  2. 0       libavfilter   2. 15. 0 /  2. 15. 0       libswscale    2.  1. 0 /  2.  1. 0       libpostproc  52.  0. 0 / 52.  0. 0     [video4linux2 @ 0x54d7a0] [4]Capabilities: 84000001     [video4linux2 @ 0x54d7a0] The V4L2 driver changed the pixel format from 0x32315559 to 0x56595559         Last message repeated 1 times     [video4linux2 @ 0x54d7a0] The V4L2 driver changed the pixel format from 0x50323234 to 0x56595559     [video4linux2 @ 0x54d7a0] The V4L2 driver set input_id: 0, input: Camera 1     [rawvideo @ 0x54f860] err{or,}_recognition separate: 1; 1     [rawvideo @ 0x54f860] err{or,}_recognition combined: 1; 1     [video4linux2 @ 0x54d7a0] All info found     [video4linux2 @ 0x54d7a0] Estimating duration from bitrate, this may be inaccurate     Input #0, video4linux2, from '/dev/video0':       Duration: N/A, start: 21891.364784, bitrate: 9216 kb/s         Stream #0.0, 1, 1/1000000: Video: rawvideo, yuyv422, 160x120, 1/30, 9216 kb/s, 30 tbr, 1000k tbn, 30 tbc     [buffer @ 0x54f220] w:160 h:120 pixfmt:yuyv422     [avsink @ 0x54d740] auto-inserting filter 'auto-inserted scaler 0' between the filter 'src' and the filter 'out'     [scale @ 0x54f7e0] w:160 h:120 fmt:yuyv422 -> w:160 h:120 fmt:yuv420p flags:0x4     [mpeg2video @ 0x54ea60] err{or,}_recognition separate: 1; 1     [mpeg2video @ 0x54ea60] err{or,}_recognition combined: 1; 1     [mpeg2video @ 0x54ea60] detected 1 logical cores     [mpeg2video @ 0x54ea60] Unsupported bit depth: 0     [rawvideo @ 0x54f860] err{or,}_recognition separate: 1; 1     [rawvideo @ 0x54f860] err{or,}_recognition combined: 1; 1     Output #0, rtp, to 'rtp://192.168.1.141:8554':       Metadata:         encoder         : Lavf53.21.1         Stream #0.0, 0, 1/90000: Video: mpeg2video, yuv420p, 160x120, 1/25, q=2-31, 2600 kb/s, 90k tbn, 25 tbc     Stream mapping:       Stream #0:0 -> #0:0 (rawvideo -> mpeg2video)     SDP:     v=0     o=- 0 0 IN IP4 127.0.0.1     s=No Name     c=IN IP4 192.168.1.141     t=0 0     a=tool:libavformat 53.21.1     m=video 8554 RTP/AVP 32     b=AS:2600          Press ctrl-c to stop encoding     *** drop!         Last message repeated 1 times     *** 1 dup!     *** 16 dup! fps= 25 q=2.0 size=    1027kB time=5.24 bitrate=1605.2kbits/s dup=1 drop=2         *** drop!         Last message repeated 11 times     *** drop!49 fps= 26 q=2.0 size=    1059kB time=5.92 bitrate=1464.9kbits/s dup=17 drop=14             Last message repeated 2 times     *** drop!76 fps= 25 q=2.0 size=    2022kB time=11.00 bitrate=1505.7kbits/s dup=17 drop=17         *** drop!48 fps= 25 q=2.0 size=    4086kB time=21.88 bitrate=1529.8kbits/s dup=17 drop=18         *** 1 dup!     *** 1 dup!0 fps= 25 q=2.0 size=    4171kB time=22.36 bitrate=1528.2kbits/s dup=18 drop=19         *** 1 dup!1 fps= 25 q=2.0 size=    4859kB time=26.00 bitrate=1530.8kbits/s dup=19 drop=19         *** 1 dup!0 fps= 25 q=2.0 size=    5152kB time=27.56 bitrate=1531.5kbits/s dup=20 drop=19         *** 1 dup!3 fps= 25 q=2.0 size=    5250kB time=28.08 bitrate=1531.7kbits/s dup=21 drop=19         *** drop!64 fps= 25 q=2.0 size=    7215kB time=38.52 bitrate=1534.5kbits/s dup=22 drop=19         *** 1 dup!6 fps= 25 q=2.0 size=    7306kB time=39.00 bitrate=1534.6kbits/s dup=22 drop=20         *** drop!07 fps= 25 q=2.0 size=    8288kB time=44.24 bitrate=1534.7kbits/s dup=23 drop=20         *** 1 dup!0 fps= 25 q=2.0 size=   10054kB time=53.56 bitrate=1537.8kbits/s dup=23 drop=21         *** 1 dup!9 fps= 25 q=2.0 size=   10342kB time=55.12 bitrate=1537.1kbits/s dup=24 drop=21             Last message repeated 1 times     *** drop!93 fps= 25 q=1.6 size=   10445kB time=55.68 bitrate=1536.7kbits/s dup=26 drop=21         *** 1 dup!     *** 7036829 dup! 25 q=2.0 size=   10630kB time=56.68 bitrate=1536.4kbits/s dup=27 drop=22       Any ideas? Thanks in advance. EDIT: Output of **v4l2-ctl --list-formats-ext** command is as below:               pi@raspberrypi ~ $ v4l2-ctl --list-formats-ext     ioctl: VIDIOC_ENUM_FMT         Index       : 0         Type        : Video Capture         Pixel Format: 'YUYV'         Name        : YUV 4:2:2 (YUYV)             Size: Discrete 640x480                 Interval: Discrete 0.033s (30.000 fps)                 Interval: Discrete 0.067s (15.000 fps)             Size: Discrete 352x288                 Interval: Discrete 0.033s (30.000 fps)                 Interval: Discrete 0.067s (15.000 fps)             Size: Discrete 320x240                 Interval: Discrete 0.033s (30.000 fps)                 Interval: Discrete 0.067s (15.000 fps)             Size: Discrete 176x144                 Interval: Discrete 0.033s (30.000 fps)                 Interval: Discrete 0.067s (15.000 fps)             Size: Discrete 160x120                 Interval: Discrete 0.033s (30.000 fps)                 Interval: Discrete 0.067s (15.000 fps)


title: How does LVM find drives after setup

text: I want to move all my 14.5 TB of media drives (not OS) to a combined LVM file system due to constant problems arranging things to fit into multiple smaller file systems. My question is if after setup any of the 6 drives moves to a different location (`/dev/sd*`), is that going to be a problem? I have always mounted them based on UUID, but I don't know LVM enough to know how it works with multiple drives. I know I can still mount the file system based on UUID, but I want to make sure LVM is not going to be messed up finding the individual parts of the system. I have to ask this since, for some reason, if I reboot with USB drives inserted they get lower `sd*` letters than some of the media drives and it causes those media drives to be rearranged for that boot only. PS. I maintain off site backups of my media so I'm not to worried about if one drive fails breaking stuff. Only mentioned since my Google searches of LVM always have someone trying to talk the person out of it because one problem loses everything.


title: Installing ia32 Libs Need to Downgrade Packages

text: I've been trying to install ia32 libs for ADB and fastboot through apt-get but I get a message stating I have held broken packages. So I have tried Aptitude and instead Aptitude keeps telling me that I need to downgrade a whole bunch of packages and uninstall a further four; Is this a safe operation to perform? I am running Linux Mint 16 "Petra" Cinnamon edition. > >                 Remove the following packages:   >            1)     gcj-4.8-jre   >            2)     gcj-4.8-jre-headless   >            3)     gcj-jre   >            4)     gcj-jre-headless   >   >                 Install the following packages:   >            5)     lib32asan0 [4.8.1-10ubuntu8 (saucy)]   >            6)     lib32atomic1 [4.8.1-10ubuntu8 (saucy)]   >            7)     lib32gcc-4.8-dev [4.8.1-10ubuntu8 (saucy)]   >            8)     lib32gcc1 [1:4.8.1-10ubuntu8 (saucy)]   >            9)     lib32gomp1 [4.8.1-10ubuntu8 (saucy)]   >           10)     lib32itm1 [4.8.1-10ubuntu8 (saucy)]   >           11)     lib32quadmath0 [4.8.1-10ubuntu8 (saucy)]   >           12)     lib32stdc++-4.8-dev [4.8.1-10ubuntu8 (saucy)]   >           13)     lib32stdc++6 [4.8.1-10ubuntu8 (saucy)]   >           14)     libc6-dev-i386 [2.17-93ubuntu4 (saucy)]   >           15)     libc6-dev-x32 [2.17-93ubuntu4 (saucy)]   >           16)     libc6-x32 [2.17-93ubuntu4 (saucy)]   >           17)     libkms1 [2.4.46-1 (saucy)]   >           18)     libstdc++-4.8-dev [4.8.1-10ubuntu8 (saucy)]   >           19)     libx32asan0 [4.8.1-10ubuntu8 (saucy)]   >           20)     libx32atomic1 [4.8.1-10ubuntu8 (saucy)]   >           21)     libx32gcc-4.8-dev [4.8.1-10ubuntu8 (saucy)]   >           22)     libx32gcc1 [1:4.8.1-10ubuntu8 (saucy)]   >           23)     libx32gomp1 [4.8.1-10ubuntu8 (saucy)]   >           24)     libx32itm1 [4.8.1-10ubuntu8 (saucy)]   >           25)     libx32quadmath0 [4.8.1-10ubuntu8 (saucy)]   >           26)     libx32stdc++-4.8-dev [4.8.1-10ubuntu8 (saucy)]   >           27)     libx32stdc++6 [4.8.1-10ubuntu8 (saucy)] >   >                 Downgrade the following packages:   >           28)     cpp-4.8 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 (saucy)]   >           29)     gcc-4.8 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 (saucy)]   >           30)     gcc-4.8-base [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           31)     libasan0 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           32)     libatomic1 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           33)     libdrm-intel1 [2.4.46-1ubuntu1 (now) -> 2.4.46-1 (saucy)]   >           34)     libdrm-nouveau2 [2.4.46-1ubuntu1 (now) -> 2.4.46-1 > (saucy)]   >           35)     libdrm-radeon1 [2.4.46-1ubuntu1 (now) -> 2.4.46-1 (saucy)]   >           36)     libdrm2 [2.4.46-1ubuntu1 (now) -> 2.4.46-1 (saucy)]   >           37)     libgcc-4.8-dev [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)] >           38)     libgcc1 [1:4.8.1-10ubuntu9 (now) -> 1:4.8.1-10ubuntu8 > (saucy)]   >           39)     libgfortran3 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           40)     libgomp1 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           41)     libitm1 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 (saucy)]   >           42)     libquadmath0 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           43)     libstdc++6 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >           44)     libtsan0 [4.8.1-10ubuntu9 (now) -> 4.8.1-10ubuntu8 > (saucy)]   >   >   >   >     Accept this solution? [Y/n/q/?] >   Here is a full console log: http://pastebin.com/sj0fS8n2


title: What handles notifications in a pure Openbox environment?

text: I'm running Debian and logging in straight to Openbox. I'm sure that I sometimes receive notifications, which I can actually theme and modify through Xfce's notification settings manager, but what is actually running in the background and displaying these notifications? Is it a part of Xfce?


title: Get the number of files that match a pattern in a directory and delete the oldest one

text: I'd like to do the following:   1. Get the number of files in a given directory that match a given pattern, for example: `ExtractBackup_{date}.tar.gz`   2. If that number is 2 or higher, delete the oldest file which matches that pattern. How do I go about doing this using a Korn Shell (`.ksh`) script?


title: Swapping <esc> and <caps lock> in a way that persists with external keyboards

text: I have a file called ~/.speedswapper which contains the following:               ! Swap caps lock and escape     remove Lock = Caps_Lock     keysym Escape = Caps_Lock     keysym Caps_Lock = Escape     add Lock = Caps_Lock      ...when I run `xmodmap ~/.speedswapper`, this switches the `esc` and `Caps Lock` keys. I have this line in my ~/.profile, so that whenever I log in these keys are switched. **However** , if I plug in an external USB keyboard, this setting doesn't seem to persist. My laptop's keyboard works perfectly well, but I have to run the command again in order for the external keyboard to switch the two keys. Fortunately, doing so doesn't seem to affect my laptop's keyboard -- they seem to synchronise. One solution would be to find some way to run that xmodmap command whenever an external keyboard is plugged in, but I'd be open to another keyswapping solution, if it would be more robust. OS is Ubuntu 13.04. Given justbrowsing's comment, it looks like this can be achieved by writing a udev rule -- I think I have to use the RUN option, and that it should be triggered on /dev/hidraw0 or /dev/hidraw1, which are the devices that appear when I plug my keyboard in... but I'm still trying to wrap my head around the concept, so I'd appreciate any help from someone who knows what they're doing with udev.


title: How can I set up byobu to use a second screen session on login?

text: **tl;dr:** I have an irssi proxy screen session running in the background. I'm running `byobu -R -S byobu;exit` in `~/.bash_profile` to start a second session instead of reconnecting to the irssi session, but it starts a third session when I log in twice (e.g. once through the local terminal and once through SSH). How can I make the secon login reconnect to the first? I had previously enabled byobu on login for my server. This worked fine, and I would get the same underlying screen session no matter where I logged in from. However, then I added a second screen session to the server's boot:               [alex@alex-ubuntu-server ~]$ cat /etc/rc.local     #!/bin/sh -e     # [clipped out default ubuntu rc.local header]          # run an irssi proxy under screen as user alex     sudo -H -u alex screen -d -m -S irssi-proxy irssi          exit 0     [alex@alex-ubuntu-server ~]$       From then on, this command (which was put in my `~/.bash_profile` by byobu configuration):               _byobu_sourced=1 . /usr/bin/byobu-launch -S byobu      would connect to the already existing irssi screen session, instead of creating a new session. This was obviously not ideal, so eventually I settled on the following command:               byobu -R -S byobu;exit      Then intention was to name the screen session, thus allowing a reconnect to the same name when I logged in again through e.g. SSH. However, when I login again, I get a fresh screen session instead of the existing one (as you can see in the example below, this has already happened once).               [alex@alex-ubuntu-server ~]$ screen -ls     There are screens on:             18036.byobu     (07/07/2013 04:26:44 PM)        (Attached)             3869.byobu      (07/05/2013 07:45:37 PM)        (Attached)             1319.irssi-proxy        (07/04/2013 05:01:54 PM)        (Detached)     3 Sockets in /var/run/screen/S-alex.          [alex@alex-ubuntu-server ~]$ ssh localhost     Ubuntu 13.04     alex@localhost's password:     # at this point the screen redrew because of the new byobu session,     # so these weren't really one after another, as shown here     alex@alex-ubuntu-server:~$ screen -ls     There are screens on:             6216.byobu      (07/07/2013 05:17:38 PM)        (Attached)             18036.byobu     (07/07/2013 04:26:44 PM)        (Attached)             3869.byobu      (07/05/2013 07:45:37 PM)        (Attached)             1319.irssi-proxy        (07/04/2013 05:01:54 PM)        (Detached)     4 Sockets in /var/run/screen/S-alex.          alex@alex-ubuntu-server:~$       I'd prefer not to switch to `tmux`. How can I construct a byobu/screen command that reconnects to the existing second screen session if possible, but otherwise starts a new (second) session?


title: Unable to install any programs

text: I'm trying to install programs but no matter what program I try installing I get the following error. For example I downloaded skype 'skype- debian_4.2.0.11-1_i386.deb' and ran the command:               $ cd downloads      And then:               $ sudo apt-get install skype-debian_4.2.0.11-1_i386      And I get the following error:               Reading package lists... Done     Building dependency tree     Reading state information... Done     E: Unable to locate package skype-debian_4.2.0.11-1_i386     E: Couldn't find any package by regex 'skype-debian_4.2.0.11-1_i386'      I'm running CrunchBang. In the `sources.list` file it says:               ## CRUNCHBANG     ## Compatible with Debian Wheezy, but use at your own risk.     deb http://packages.crunchbang.org/waldorf waldorf main     #deb-src http://packages.crunchbang.org/waldorf waldorf main          ## DEBIAN     deb http://http.debian.net/debian wheezy main contrib non-free     #deb-src http://http.debian.net/debian wheezy main contrib non-free          ## DEBIAN SECURITY     deb http://security.debian.org/ wheezy/updates main     #deb-src http://security.debian.org/ wheezy/updates main          And in the folder there is one file called google-chrome.list and it says in it          ### THIS FILE IS AUTOMATICALLY CONFIGURED ###     # You may comment out this entry, but any other modifications may be lost.     deb http://dl.google.com/linux/chrome/deb/ stable main      ### EDIT #1 When I try to run the command:               $ sudo gdebi skype-debian_4.2.0.11-1_i386.deb      I get this:               Reading package lists... Done     Building dependency tree         Reading state information... Done     Building data structures... Done      This package is uninstallable     Wrong architecture 'i386'


title: Piping periodic data between Python scripts

text: > How to receive data from the environment e.g. bash I am trying to launch two Python scripts in `bash` and pipe `stdout` from one of them to `stdin` of the other. The first script outputs a single number every second.               ./script1 | ./script2     ./script1 > ~/file &; tail -f ~/file      I tried those, but can't get it working. `script1` outputs via Python's `print`, while script2 is tested with `echo "21.11 22.23 33.233" | ./script2` and is known to work. If I terminate `script1` ofter some time, and then `cat ~/file`, I see the actual data. However, at the time of execution, neither of the above examples work. How do I make this work? I would like to be able to work both with and without intermediate file.


title: Looking for simple photo organizing software for Linux

text: I am looking for a simple Linux software to organize photos. What exactly I want to do with this application is the following: I want to view all images in a given folder and just tag/star/mark some of them with by simple key pressing or a simple mouse click. No menu, not complicated 10-mouse click journey, just ONE key pressing/mouse click and on to the next image. After I have selected a couple of images that way, I want them moved to another directory. Is there such a simple application? I just want to simply organize my photos in different folders, as simple as that. No tagging which is software-dependent, as I want to view those images on differrent OS, like Linux, Windows, on TV, ... Therefore, no special tagging format, just simple reorganizing photos on the touch of a simple keystroke...


title: thoroughly find all links (hard and symlinks, and any combination thereof) leading to a file/dir

text: I read "most" of the proposed questions, but I believe they all miss the complexity of the right answer. I want, only using "basic" commands (for maximum portability) (i.e., something that would work on AIX / Linux / etc., not just something using a recent nicety ^^), to find **all** the files (symlinks, hardlinks and combinations thereof) pointing to a specific file/dir. Be careful to not rush to answer `find / -ls | grep ....` : it will miss many cases. See my links below, mixing hardlinks, symlinks, relative-and-absolute paths (and also play with symlinks "././././." possibilities) ie   * hardlinks and symlinks can be "nested", ad-inifinitum...   * some symlinks could be with the full path, others with a relative path,    * those paths (relative or absolute) could be very complex (ex: /tmp/././../etc/file )   * a symlink could lead to a file, which hardlink to another, which is a symlink to a third, which ends up [after some more iteration] to the final destination... In the end, I "just" need to find out a way to know **what is the "final destination" of any file/link** (ie, which inode will be accessed in the end?). But it's _really_ tough (unless some magical function will tell me "the final destination inode is : ...". That's what I need!) I thought I could simply use '-H' or '-L' options of find, but (I'm probably dumb...) it didn't work... yet. Any info welcomed (but please, using find/ls/etc, not some "nice utility only available on linux") Try to create some different links to the "/tmp/A" directory, and find a way to find and list them all:               mkdir /tmp/A    /tmp/B     ln -s /tmp/A/   /tmp/B/D  #absolute symlink, with a training "/"     ln -s ../A      /tmp/B/E     #relative symlink     ln -s /tmp/A/.  /home/F  #absolute symlink, with a trailing "/."     ln -s ../tmp/A/./.  /var/L  #let's get craaaaaaazy! symlinks are "fun"...     ln    /tmp/B/D  /etc/G    #Hard-link to the symlink file /tmp/B/D, which itself symlink to /tmp/A/ witch ends up being the same as "/tmp/A" in most cases.     ln    /etc/G    /etc/G2   #and a duplicate of the previous one, just to be sure [so /etc/G, /etc/G2, and /tmp/B/D have same inode, but it's a different inode from the final destination... :(     ln -s etc/G /thatsenough   #symlink again, for further chaining      and then some tries:               find -H / -ls   # show inodes of the links and symlinks, not of the "final" directory     find -L / -ls   # same thing (I do try that on an OLD AIX ...)     find -H / -inum 123456 -ls  #if /tmp/A/. has inode 123456. This lists *only* hardlinks to /tmp/A, ie will only print a subset (and /tmp/A have to be a file in that case)      I expected to see the final inode (123456) in front of all the paths, in one of those invocation (I also added '-follow' to both), but I always see the inodes of the links, not of the "final destination" (i.e., /tmp/A) What could I use to find out the "final inode" I end up accessing? [the OS manages it, but can a "simple" command tell me beforehand "through _that_ file, you will open _that_ final inode!"?]


title: What is hvc0? (appearing in "who" list)

text: I have an Ubuntu Server, and when I type `who`, to see who's connected, I can see that there's a user connected, and instead of being logged to a `pts/x`, he's connected to `hvc0`. Is there something to worry about?


title: Copy multiple files and append to end of filename

text: Seems like I really shouldn't need to create a script for this. I'd like to do something `cp /etc/*.conf $1.orig` or `cp /etc/{a.conf,b.conf} _firstarg_.orig` Is there a quick and painless way of doing this?


title: Can I create a local only guest account?

text: Is it possible to create a "guest" account in Linux? by "guest" account I mean an account that does not require a password to log in graphically. I want this account for when people come over and are like "can I use your computer to check my email". Then I don't have to worry about them snooping my stuff. I realize that some of this may require doing stuff specific to the login manager, since I wouldn't be surprised that this is a common problem, it'd be best to include instructions for `xdm`, `kdm`, and `gdm` and any other login managers that I haven't listed.


title: Extract file name from find command

text: I am trying to extract the file name and attaching to mail. But when I send mail the attachment is coming with path name and file name. Ex: `dir=/home/as123/bill` and `filename=abc.pdf.Z` and I am getting attachment like               homeas123billabc.pdf.Z          find $dir -ctime -1 -type f -name "abc*pdf*" -exec basename {} \; -exec uuencode {} {} \; | mailx -s "north" abc@gmail.com      `printf` not installed on my machine, without that how to write my script to get only file name as attachment?


title: Linux - why is kernel.shmall so low by default?

text: I run DB2 on Linux where I have to allocate the vast majority of memory on the machine to shared memory segments. This page is typical of the info that I've found about shmall/shmmax: http://www.pythian.com/news/245/the-mysterious-world-of-shmmax-and-shmall/ My system is running fine now, but I'm wondering if there's a historical or philosophical reason why shared memory is so low by default. In other words, why not let shmall default to the max physical memory on the machine? Or in other words, why should a typical admin need to be 'protected from himself' if an app happens to use a lot of shared memory, and have to go in and change these settings? The only thing I can think of is that it does let me set an upper bound to how much memory DB2 can use, but that's a special case.


title: Extensions "grayed out" on extensions.gnome.org

text: The site extensions.gnome.org loads OK, but all of the extensions appear to be "grayed out" (reduced opacity) as though they are not available. At the top of the site, I have "current version" selected in the _Compatible With_ drop down. According to this screenshot, I should be seeing toggle switches at the top of compatible extensions. ![enter image description here](http://i.stack.imgur.com/khhCK.png) Prior to `yum install gnome-shell-browser-plugin` I was seeing a message that Gnome couldn't determine my Gnome version. Once that was installed, I no longer see that warning - but appear to be missing the "On/Off" toggle sliders to install additional plugins. Is something else required for this to work correctly?


title: Installing courier-mta causes sendmail to be installed instead

text: My Debian workstation will not install courier-mta. The command `aptitude install courier-mta` appears to complete without error, but actually installs sendmail instead. # What I did I'll start without any packages installed which provide mail-transfer-agent:               dpkg --get-selections 'courier*' 'sendmail*' 'exim*' sensible-mda | awk '{print $1}' | xargs sudo dpkg --purge --force-depends     ...     root@treebeard:/etc/logcheck/violations.ignore.d$ dpkg -l 'courier*' 'sendmail*' 'exim*' sensible-mda     Desired=Unknown/Install/Remove/Purge/Hold     | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend     |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)     ||/ Name                                            Version                      Architecture                 Description     +++-===============================================-============================-============================-===================================================================================================     un  exim4                                           <none>                                                    (no description available)     dpkg-query: no packages found matching courier*     dpkg-query: no packages found matching sendmail*     dpkg-query: no packages found matching sensible-mda      And then install courier-mta:               root@treebeard:/etc/logcheck/violations.ignore.d$ sudo aptitude install courier-mta     The following NEW packages will be installed:       courier-authdaemon{a} courier-authlib{a} courier-authlib-userdb{a} courier-base{a} courier-mta      0 packages upgraded, 5 newly installed, 0 to remove and 0 not upgraded.     Need to get 0 B/1,261 kB of archives. After unpacking 2,887 kB will be used.     Do you want to continue? [Y/n/?]      Preconfiguring packages ...                   Configuring courier-base     ------------------------          Courier uses several configuration files in /etc/courier. Some of these files can be replaced by a subdirectory whose contents are concatenated and treated as a single, consolidated, configuration file.          The web-based administration provided by the courier-webadmin package relies on configuration directories instead of configuration files. If you agree, any directories needed for the web-based administration tool     will be created unless there is already a plain file in place.          Create directories for web-based administration? no               Configuring courier-mta     -----------------------          Please specify a valid email domain. Most header rewriting functions will append this domain to all email addresses which do not specify a domain, such as local accounts.          Default domain: fake.domain               Please specify a valid value for the "From" header for mail delivery notifications. These notifications cannot be sent without that setting.          "From" header for delivery notifications: noreply@fake.domain               Selecting previously unselected package courier-authlib.     (Reading database ... 249566 files and directories currently installed.)     Unpacking courier-authlib (from .../courier-authlib_0.63.0-6+b1_i386.deb) ...     Selecting previously unselected package courier-authdaemon.     Unpacking courier-authdaemon (from .../courier-authdaemon_0.63.0-6+b1_i386.deb) ...     Selecting previously unselected package courier-authlib-userdb.     Unpacking courier-authlib-userdb (from .../courier-authlib-userdb_0.63.0-6+b1_i386.deb) ...     Selecting previously unselected package courier-base.     Unpacking courier-base (from .../courier-base_0.68.2-1_i386.deb) ...     Selecting previously unselected package courier-mta.     Unpacking courier-mta (from .../courier-mta_0.68.2-1_i386.deb) ...     Adding 'diversion of /usr/bin/addcr to /usr/bin/addcr.ucspi-tcp by courier-mta'     Adding 'diversion of /usr/share/man/man1/addcr.1.gz to /usr/share/man/man1/addcr.ucspi-tcp.1.gz by courier-mta'     Processing triggers for man-db ...     Setting up courier-authlib (0.63.0-6+b1) ...     Setting up courier-authdaemon (0.63.0-6+b1) ...     [ ok ] Starting Courier authentication services: authdaemond.     Setting up courier-authlib-userdb (0.63.0-6+b1) ...     Setting up courier-base (0.68.2-1) ...     update-alternatives: using /usr/bin/deliverquota.courier to provide /usr/bin/deliverquota (deliverquota) in auto mode     update-alternatives: using /usr/share/man/man5/maildir.courier.5.gz to provide /usr/share/man/man5/maildir.5.gz (maildir.5.gz) in auto mode     update-alternatives: using /usr/bin/maildirmake.courier to provide /usr/bin/maildirmake (maildirmake) in auto mode     update-alternatives: using /usr/share/man/man7/maildirquota.courier.7.gz to provide /usr/share/man/man7/maildirquota.7.gz (maildirquota.7.gz) in auto mode     update-alternatives: using /usr/bin/makedat.courier to provide /usr/bin/makedat (makedat) in auto mode     Setting up courier-mta (0.68.2-1) ...     update-alternatives: using /usr/bin/lockmail.courier to provide /usr/bin/lockmail (lockmail) in auto mode     update-alternatives: using /usr/bin/preline.courier to provide /usr/bin/preline (preline) in auto mode     Starting Courier mail server: done.     Starting Courier mail filter: done.     Starting Courier SMTP server: done.          Current status: 0 broken [-2].      # The problem courier-mta appeared to have installed without error, and yet courier-mta is not installed. Instead, sendmail is installed:               root@treebeard:/etc/logcheck/violations.ignore.d$ dpkg -l 'courier*' 'sendmail*' 'exim*' sensible-mda     Desired=Unknown/Install/Remove/Purge/Hold     | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend     |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)     ||/ Name                                            Version                      Architecture                 Description     +++-===============================================-============================-============================-===================================================================================================     ii  courier-authdaemon                              0.63.0-6+b1                  i386                         Courier authentication daemon     ii  courier-authlib                                 0.63.0-6+b1                  i386                         Courier authentication library     ii  courier-authlib-userdb                          0.63.0-6+b1                  i386                         userdb support for the Courier authentication library     un  courier-authmysql                               <none>                                                    (no description available)     un  courier-authpostgresql                          <none>                                                    (no description available)     ii  courier-base                                    0.68.2-1                     i386                         Courier mail server - base system     un  courier-debug                                   <none>                                                    (no description available)     un  courier-doc                                     <none>                                                    (no description available)     un  courier-faxmail                                 <none>                                                    (no description available)     un  courier-filter-perl                             <none>                                                    (no description available)     un  courier-imap                                    <none>                                                    (no description available)     rc  courier-mta                                     0.68.2-1                     i386                         Courier mail server - ESMTP daemon     un  couriergrey                                     <none>                                                    (no description available)     un  exim4                                           <none>                                                    (no description available)     ii  sendmail                                        8.14.4-4                     all                          powerful, efficient, and scalable Mail Transport Agent     ii  sendmail-base                                   8.14.4-4                     all                          powerful, efficient, and scalable Mail Transport Agent     ii  sendmail-bin                                    8.14.4-4                     i386                         powerful, efficient, and scalable Mail Transport Agent     ii  sendmail-cf                                     8.14.4-4                     all                          powerful, efficient, and scalable Mail Transport Agent     un  sendmail-doc                                    <none>                                                    (no description available)     un  sendmail-tls                                    <none>                                                    (no description available)     ii  sensible-mda                                    8.14.4-4                     i386                         Mail Delivery Agent wrapper      sendmail-bin (and its requirements) have been installed. Packages required by courier-mta have been installed, but courier-mta itself has not. # History This is a Debian Wheezy (stable) box. It was running Debian Jessy (testing), but I downgraded it to Wheezy by means of this /etc/apt/preferences file:               Package: *     Pin: release a=stable     Pin-Priority: 1001      and by changing /etc/apt/sources file to:               deb http://ftp.debian.org/debian wheezy main non-free contrib     deb http://security.debian.org/ wheezy/updates main contrib non-free      and by a means of a long series of apt-get/dpkg commands which I do not recall. I do recall there being much swearing. # The question **Why, when I try to install courier-mta, is sendmail-bin being installed instead?**


title: Execute bash commands over SSH while staying in interactive mode afterwards

text: Probably it is a weird thing I would like to achieve but:   I would like to SSH to a remote host and then execute some bash commands like "alias" automatically to use them afterwards in an interactive mode. The remote host does not allow the personal environment. Is this possible? Would "expect" do it? Or is there any other way to achieve this?   Basically I would like to have my bashrc without modifying any files on the remote host.


title: Wait until no incoming network connection for N minutes, then execute a command

text: I want to put my Debian Wheezy home server to sleep, if it wasn't accessed through the network for a certain amount of time. I thought of a bash script that uses netstat to count the number of active connections, sleeps for some seconds, runs netstat again, and so on. Is there any better way to achieve this without using sleeping every second? Is there any way to react to the event 'incoming network connection' and reset some kind of countdown timer?


title: How to change run-level for a session? (from graphics to command-line only)

text: When I type `init 1` the computer freezes. When I am running the 'normal' level of 2, how can I move to a command-line only running? I know that I can reach the command-line with Alt + Ctrl + F1-6, but then all programs for graphical display will still be running (and consuming the battery).


title: Installing Lispworks on rhel 6.5 Workstation. Error when loading application

text: Does anybody know what this error means and how to get Lispworks Personal edition to run on Redhat? Error:               Error during GUI startup:     Could not register handle for external module "-lgthread-2.0":     libgthread-2.0.so: cannot open shared object file: No such file or directory.      Here is the whole output: sudo /usr/bin/lispworks-personal-6-1-1-x86-linux               LispWorks(R): The Common Lisp Programming Environment Personal Edition     Copyright (C) 1987-2012 LispWorks Ltd.  All rights reserved.     Version 6.1.1     Saved by LispWorks as lispworks-personal-6-1-1-x86-linux, at 06 Dec 2012     16:51     User root on HostName     Error during GUI startup:     Could not register handle for external module "-lgthread-2.0":     libgthread-2.0.so: cannot open shared object file: No such file or        directory.          DESCRIPTION: Output Backtrace <and a simple test case, if possible>          IMPACT: Broken/Annoying/Data Loss/Missing Error/New Feature/Performance Loss          URGENCY: ASAP/Current Release/Next Release/Future Release/None                    PRODUCT CONFIGURATION:            LispWorks Personal Edition 6.1.1          Process name: /usr/bin/lispworks-personal-6-1-1-x86-linux        ID: 9597    Started at: 2014/03/20 23:04:07          Save history:          1: lispworks-6-1-0-0-x86-linux-release-base     Saved by davef as lispworks-6-1-0-0-x86-linux-release-base, at 03 Nov 2011 13:25          2: lispworks-6-1-0-0-x86-linux-release-gtk-shaken     Saved by davef as lispworks-6-1-0-0-x86-linux-release-gtk-shaken, at 03 Nov 2011 14:00          3: lispworks-6-1-1-0-x86-linux-release-gtk-shaken     Saved by davef as lispworks-personal-6-1-1-x86-linux, at 06 Dec 2012 16:51     LispWorks 6.1.1 - Personal Edition          Loaded Modules:           Public patches:      Private patches:  CAPI-GTK-DESTROY-REPRESENTATION          Foreign modules:       #<FLI::INTERNAL-MODULE :LISP : exports = 0>       #<FLI::INTERNAL-MODULE :CALLBACKS : exports = 0>       #<FLI::EXTERNAL-MODULE "-lgthread-2.0"  : handle = #x00000000; exports = 0>          Signal Handlers     2       SYSTEM::SIGINT-HANDLER     13      SYSTEM::THE-NULL-FUNCTION     17      SYSTEM::GET-CHILDREN-INF          HOST CONFIGURATION:            Zundrum (x86_64), Linux 2.6.32-431.5.1.el6.x86_64       Red Hat Enterprise Linux Workstation release 6.5 (Santiago)       Kernel \r on an \m          LWSerialNumber: Unknown          Site: Unknown          GTK+ not loaded          Backtrace:     #<The COMMON-LISP-USER package, 1/16 internal, 0/4 external>                    Call to (SUBFUNCTION 1 ENVIRONMENT:START-ENVIRONMENT) {offset 186}       SYSTEM::C : #<SIMPLE-ERROR 200C2DAB>          Binding frame:       CONDITIONS::*IN-SIGNAL-CATCH* : T          Handler frame: NIL     Call to SIGNAL {offset 1446}       CONDITIONS::DATUM     : #<SIMPLE-ERROR 200C2DAB>       CONDITIONS::ARGUMENTS : NIL          Binding frame:       CONDITIONS::*IN-SIGNAL-CATCH* : NIL          Catch frame: CONDITIONS::SIGNAL-CATCH          Binding frame:       CONDITIONS::*BROKEN-ON-SIGNALS* : NIL          Call to CONDITIONS::CONDITIONS-ERROR {offset 430}       CONDITIONS::DATUM     : "Could not register handle for external module ~S:~% ~A."       CONDITIONS::ARGUMENTS : ("-lgthread-2.0" "libgthread-2.0.so: cannot open shared object file: No such file or directory")          Call to ERROR {offset 67}       SYSTEM::ESTRING : "Could not register handle for external module ~S:~% ~A."       SYSTEM::EARGS   : ("-lgthread-2.0" "libgthread-2.0.so: cannot open shared object file: No such file or directory")          Binding frame:       FLI::*DLOPEN-FLAGS* : T          Call to FLI::CONNECT-TO-EXTERNAL-MODULE {offset 319}       FLI::MODULE : #<FLI::EXTERNAL-MODULE "-lgthread-2.0"  : handle = #x00000000; exports = 0>       TYPE        : :MANUAL       FLI::ERRORP : T          Call to FLI::CREATE-EXTERNAL-MODULE {offset 275}       FLI::NAME             : "-lgthread-2.0"       FLI::CONNECTION-STYLE : :IMMEDIATE       FLI::FILENAME         : NIL       FLI::MODULE           : #<FLI::EXTERNAL-MODULE "-lgthread-2.0"  : handle = #x00000000; exports = 0>       OPEN                  : T       FLI::LIFETIME         : :SESSION       FLI::DLOPEN-FLAGS     : FLI::DEFAULT       FLI::ADD-LIB-PATH     : NIL          Call to FLI:REGISTER-MODULE {offset 146}       FLI::NAME             : "-lgthread-2.0"       FLI::CONNECTION-STYLE : :IMMEDIATE       FLI::LIFETIME         : :SESSION       FLI::REAL-NAME        : NIL       FLI::FILE-NAME        : NIL       FLI::DLOPEN-FLAGS     : FLI::DEFAULT       FLI::ADD-LIB-PATH     : NIL          Call to LWGTK:INITIALIZE-GTK-LIBRARY {offset 999}          Call to CAPI-GTK-LIBRARY::ENSURE-GTK-INITIALIZED {offset 21}          Call to (METHOD CAPI-LIBRARY:LIBRARY-READY-TO-START ((EQL :GTK))) {offset 11}       CAPI-GTK-LIBRARY::LOOK-AND-FEEL : :DONT-KNOW          Call to CLOS::CACHE-MISS-FUNCTION {offset 311}       CLOS::ARGS                   : (:GTK)       CLOS::.CACHE-INFO.  {Closed} : #<CLOS::CACHE-INFO CAPI-LIBRARY:LIBRARY-READY-TO-START [8/2] >       CLOS::.GF.  {Closed}         : #<STANDARD-GENERIC-FUNCTION CAPI-LIBRARY:LIBRARY-READY-TO-START 217FEBA2>          Call to CAPI-INTERNALS:START-ENVIRONMENT {offset 60}       CAPI::ARGS            : (:START-FUNCTIONS ((LISPWORKS-TOOLS::START-LISPWORKS-TOOLS :TOOLS (LISPWORKS-TOOLS:LISPWORKS-ECHO-PODIUM LISPWORKS-TOOLS:LISTENER))) :ENVIRONMENT :CAPI)       CAPI::ENVIRONMENT     : :CAPI       PACKAGE               : NIL       CAPI::LIBRARY         : NIL       CAPI::START-FUNCTIONS : ((LISPWORKS-TOOLS::START-LISPWORKS-TOOLS :TOOLS (LISPWORKS-TOOLS:LISPWORKS-ECHO-PODIUM LISPWORKS-TOOLS:LISTENER)))          Call to ENVIRONMENT::START-CAPI-ENVIRONMENT {offset 24}       LISPWORKS-TOOLS::ARGS : NIL          Call to CLOS::CACHE-MISS-FUNCTION {offset 311}       CLOS::ARGS                   : (#<ENVIRONMENT::CAPI-ENVIRONMENT 21BCCF4B> NIL)       CLOS::.CACHE-INFO.  {Closed} : #<CLOS::CACHE-INFO ENVIRONMENT-INTERNALS:ENVIRONMENT-START [8/2] >       CLOS::.GF.  {Closed}         : #<STANDARD-GENERIC-FUNCTION ENVIRONMENT-INTERNALS:ENVIRONMENT-START 20979E5A>          Handler frame: ((ERROR . #<Function 1 subfunction of ENVIRONMENT:START-ENVIRONMENT 21E1A0EA>))     Call to ENVIRONMENT:START-ENVIRONMENT {offset 158}       SYSTEM::ARGS          : NIL       SYSTEM::OLD  {Closed} : #<Function ENVIRONMENT:START-ENVIRONMENT 20979E92>          Binding frame:       MP:*INITIAL-PROCESSES* : (("The idle process" (:PRIORITY -536870912 :RESTART-ACTION :CONTINUE :INTERNAL-SERVER :IDLE) MP::PROCESS-IDLE-FUNCTION))          Call to ENVIRONMENT::I-RESTART-WITH-ENVIRONMENT-AUX {offset 210}       ENVIRONMENT::TTY-LISTENER-P : NIL          Call to SYSTEM::RESTART-HOOK {offset 96}       FUNCTION : SYSTEM::%TOP-LEVEL          Restart frame: (SYSTEM::TOP-LEVEL)     Catch frame: (SYSTEM::IN-START-FUNCTION-ONCE . RESTART-CASE)          Catch frame: (SYSTEM::IN-START-FUNCTION-ONCE . 1)          Catch frame: SYSTEM::EXIT-LISPWORKS          Call to SYSTEM::IN-START-FUNCTION-ONCE {offset 421}          Catch frame: SYSTEM::START-UP          Catch frame: SYSTEM::IN-START-FUNCTION          Call to SYSTEM::IN-START-FUNCTION {offset 57}          Call to SYSTEM::CALL-IN-START-FUNCTION {offset 12}          Catch frame: (NIL)          Call to SYSTEM::START-FUNCTION {offset 50}       SYSTEM::GC-MESSAGES : :DONT-KNOW               SYSTEM::START-FUNCTION           Generation 0:  Total Size 515K, Allocated 490K, Free 17K                Segment 20090128: Total Size 507K, Allocated 490K, Free 13K                         minimum free space 64K,                            Awaiting promotion = 0K, sweeps before promotion =10               Segment 21EDE100: Total Size 7K, Allocated 0K, Free 3K                         minimum free space 0K,                            Awaiting promotion = 0K, sweeps before promotion =2      Generation 1:  Total Size 308K, Allocated 110K, Free 189K                Segment 2070F0C0: Total Size 68K, Allocated 0K, Free 64K                         minimum free space 3K,                            Awaiting promotion = 0K, sweeps before promotion =4               Segment 200540A8: Total Size 240K, Allocated 110K, Free 125K                         minimum free space 0K, static      Generation 2:  Total Size 68K, Allocated 0K, Free 64K                Segment 20F1C640: Total Size 68K, Allocated 0K, Free 64K                         minimum free space 117K,                            Awaiting promotion = 0K, sweeps before promotion =4      Generation 3:  Total Size 30387K, Allocated 30247K, Free 128K                Segment 2010F0C0: Total Size 6144K, Allocated 6139K, Free 0K                         minimum free space 3K,                            Awaiting promotion = 0K, sweeps before promotion =10               Segment 20F2D6B8: Total Size 16066K, Allocated 15934K, Free 128K                         minimum free space 0K,                            Awaiting promotion = 0K, sweeps before promotion =10               Segment 20720138: Total Size 8177K, Allocated 8173K, Free 0K                         minimum free space 0K,                            Awaiting promotion = 0K, sweeps before promotion =10          Total Size 31616K, Allocated 30848K, Free 398K      EDIT: Here is the output from yum install glib2-devel               Setting up Install Process     Package glib2-devel-2.26.1-7.el6_5.x86_64 already installed and latest version     Nothing to do      Here is libgthread*.so               sudo find /*/*/libgthread*.so     /usr/lib64/libgthread-2.0.so      Here is ldd lispworks...               ldd /usr/bin/lispworks-personal-6-1-1-x86-linux          linux-gate.so.1 =>  (0x00a8b000)         libdl.so.2 => /lib/libdl.so.2 (0x00d45000)         libpthread.so.0 => /lib/libpthread.so.0 (0x00402000)         libc.so.6 => /lib/libc.so.6 (0x0087e000)         /lib/ld-linux.so.2 (0x0085c000)      EDIT: Here the error I get on my Fedora 20 x86_64 KDE               ~]$ lispworks-personal-6-1-1-x86-linux      LispWorks(R): The Common Lisp Programming Environment Personal Edition     Copyright (C) 1987-2012 LispWorks Ltd.  All rights reserved.     Version 6.1.1     Saved by LispWorks as lispworks-personal-6-1-1-x86-linux, at 06 Dec 2012 16:51     User root on Zundrum     Error during GUI startup:       Could not register handle for external module "-lgtk-x11-2.0":      libgtk-x11-2.0.so: cannot open shared object file: No such file or directory.          DESCRIPTION: Output Backtrace <and a simple test case, if possible>          IMPACT: Broken/Annoying/Data Loss/Missing Error/New Feature/Performance Loss          URGENCY: ASAP/Current Release/Next Release/Future Release/None                    PRODUCT CONFIGURATION:            LispWorks Personal Edition 6.1.1          Process name: /home/kristjan/bin/lispworks-personal-6-1-1-x86-linux        ID: 2527    Started at: 2014/03/25 18:37:44          Save history:          1: lispworks-6-1-0-0-x86-linux-release-base     Saved by davef as lispworks-6-1-0-0-x86-linux-release-base, at 03 Nov 2011 13:25          2: lispworks-6-1-0-0-x86-linux-release-gtk-shaken     Saved by davef as lispworks-6-1-0-0-x86-linux-release-gtk-shaken, at 03 Nov 2011 14:00          3: lispworks-6-1-1-0-x86-linux-release-gtk-shaken     Saved by davef as lispworks-personal-6-1-1-x86-linux, at 06 Dec 2012 16:51     LispWorks 6.1.1 - Personal Edition          Loaded Modules:           Public patches:      Private patches:  CAPI-GTK-DESTROY-REPRESENTATION          Foreign modules:       #<FLI::INTERNAL-MODULE :LISP : exports = 0>       #<FLI::INTERNAL-MODULE :CALLBACKS : exports = 0>       #<FLI::EXTERNAL-MODULE "-lgthread-2.0"  {/lib/libgthread-2.0.so.0}: handle = #x09D30DE0; exports = 0>       #<FLI::EXTERNAL-MODULE "-lgtk-x11-2.0"  : handle = #x00000000; exports = 0>          Signal Handlers     2       SYSTEM::SIGINT-HANDLER     13      SYSTEM::THE-NULL-FUNCTION     17      SYSTEM::GET-CHILDREN-INF          HOST CONFIGURATION:            Zundrum (x86_64), Linux 3.13.6-200.fc20.x86_64       Fedora release 20 (Heisenbug)       Kernel \r on an \m (\l)          LWSerialNumber: Unknown          Site: Unknown          GTK+ not loaded          Backtrace:     #<The COMMON-LISP-USER package, 1/16 internal, 0/4 external>                    Call to (SUBFUNCTION 1 ENVIRONMENT:START-ENVIRONMENT) {offset 186}       SYSTEM::C : #<SIMPLE-ERROR 200B5DA3>          Binding frame:       CONDITIONS::*IN-SIGNAL-CATCH* : T          Handler frame: NIL     Call to SIGNAL {offset 1446}       CONDITIONS::DATUM     : #<SIMPLE-ERROR 200B5DA3>       CONDITIONS::ARGUMENTS : NIL          Binding frame:       CONDITIONS::*IN-SIGNAL-CATCH* : NIL          Catch frame: CONDITIONS::SIGNAL-CATCH          Binding frame:       CONDITIONS::*BROKEN-ON-SIGNALS* : NIL          Call to CONDITIONS::CONDITIONS-ERROR {offset 430}       CONDITIONS::DATUM     : "Could not register handle for external module ~S:~% ~A."       CONDITIONS::ARGUMENTS : ("-lgtk-x11-2.0" "libgtk-x11-2.0.so: cannot open shared object file: No such file or directory")          Call to ERROR {offset 67}       SYSTEM::ESTRING : "Could not register handle for external module ~S:~% ~A."       SYSTEM::EARGS   : ("-lgtk-x11-2.0" "libgtk-x11-2.0.so: cannot open shared object file: No such file or directory")          Binding frame:       FLI::*DLOPEN-FLAGS* : T          Call to FLI::CONNECT-TO-EXTERNAL-MODULE {offset 319}       FLI::MODULE : #<FLI::EXTERNAL-MODULE "-lgtk-x11-2.0"  : handle = #x00000000; exports = 0>       TYPE        : :MANUAL       FLI::ERRORP : T          Call to FLI::CREATE-EXTERNAL-MODULE {offset 275}       FLI::NAME             : "-lgtk-x11-2.0"       FLI::CONNECTION-STYLE : :IMMEDIATE       FLI::FILENAME         : NIL       FLI::MODULE           : #<FLI::EXTERNAL-MODULE "-lgtk-x11-2.0"  : handle = #x00000000; exports = 0>       OPEN                  : T       FLI::LIFETIME         : :SESSION       FLI::DLOPEN-FLAGS     : FLI::DEFAULT       FLI::ADD-LIB-PATH     : NIL          Call to FLI:REGISTER-MODULE {offset 146}       FLI::NAME             : "-lgtk-x11-2.0"       FLI::CONNECTION-STYLE : :IMMEDIATE       FLI::LIFETIME         : :SESSION       FLI::REAL-NAME        : NIL       FLI::FILE-NAME        : NIL       FLI::DLOPEN-FLAGS     : FLI::DEFAULT       FLI::ADD-LIB-PATH     : NIL          Call to LWGTK:INITIALIZE-GTK-LIBRARY {offset 999}          Call to CAPI-GTK-LIBRARY::ENSURE-GTK-INITIALIZED {offset 21}          Call to (METHOD CAPI-LIBRARY:LIBRARY-READY-TO-START ((EQL :GTK))) {offset 11}       CAPI-GTK-LIBRARY::LOOK-AND-FEEL : :DONT-KNOW          Call to CLOS::CACHE-MISS-FUNCTION {offset 311}       CLOS::ARGS                   : (:GTK)       CLOS::.CACHE-INFO.  {Closed} : #<CLOS::CACHE-INFO CAPI-LIBRARY:LIBRARY-READY-TO-START [8/2] >       CLOS::.GF.  {Closed}         : #<STANDARD-GENERIC-FUNCTION CAPI-LIBRARY:LIBRARY-READY-TO-START 217FEBA2>          Call to CAPI-INTERNALS:START-ENVIRONMENT {offset 60}       CAPI::ARGS            : (:START-FUNCTIONS ((LISPWORKS-TOOLS::START-LISPWORKS-TOOLS :TOOLS (LISPWORKS-TOOLS:LISPWORKS-ECHO-PODIUM LISPWORKS-TOOLS:LISTENER))) :ENVIRONMENT :CAPI)       CAPI::ENVIRONMENT     : :CAPI       PACKAGE               : NIL       CAPI::LIBRARY         : NIL       CAPI::START-FUNCTIONS : ((LISPWORKS-TOOLS::START-LISPWORKS-TOOLS :TOOLS (LISPWORKS-TOOLS:LISPWORKS-ECHO-PODIUM LISPWORKS-TOOLS:LISTENER)))          Call to ENVIRONMENT::START-CAPI-ENVIRONMENT {offset 24}       LISPWORKS-TOOLS::ARGS : NIL          Call to CLOS::CACHE-MISS-FUNCTION {offset 311}       CLOS::ARGS                   : (#<ENVIRONMENT::CAPI-ENVIRONMENT 21BCCF4B> NIL)       CLOS::.CACHE-INFO.  {Closed} : #<CLOS::CACHE-INFO ENVIRONMENT-INTERNALS:ENVIRONMENT-START [8/2] >       CLOS::.GF.  {Closed}         : #<STANDARD-GENERIC-FUNCTION ENVIRONMENT-INTERNALS:ENVIRONMENT-START 20979E5A>          Handler frame: ((ERROR . #<Function 1 subfunction of ENVIRONMENT:START-ENVIRONMENT 21E1A0EA>))     Call to ENVIRONMENT:START-ENVIRONMENT {offset 158}       SYSTEM::ARGS          : NIL       SYSTEM::OLD  {Closed} : #<Function ENVIRONMENT:START-ENVIRONMENT 20979E92>          Binding frame:       MP:*INITIAL-PROCESSES* : (("The idle process" (:PRIORITY -536870912 :RESTART-ACTION :CONTINUE :INTERNAL-SERVER :IDLE) MP::PROCESS-IDLE-FUNCTION))          Call to ENVIRONMENT::I-RESTART-WITH-ENVIRONMENT-AUX {offset 210}       ENVIRONMENT::TTY-LISTENER-P : NIL          Call to SYSTEM::RESTART-HOOK {offset 96}       FUNCTION : SYSTEM::%TOP-LEVEL          Restart frame: (SYSTEM::TOP-LEVEL)     Catch frame: (SYSTEM::IN-START-FUNCTION-ONCE . RESTART-CASE)          Catch frame: (SYSTEM::IN-START-FUNCTION-ONCE . 1)          Catch frame: SYSTEM::EXIT-LISPWORKS          Call to SYSTEM::IN-START-FUNCTION-ONCE {offset 421}          Catch frame: SYSTEM::START-UP          Catch frame: SYSTEM::IN-START-FUNCTION          Call to SYSTEM::IN-START-FUNCTION {offset 57}          Call to SYSTEM::CALL-IN-START-FUNCTION {offset 12}          Catch frame: (NIL)          Call to SYSTEM::START-FUNCTION {offset 50}       SYSTEM::GC-MESSAGES : :DONT-KNOW               SYSTEM::START-FUNCTION           Generation 0:  Total Size 515K, Allocated 260K, Free 247K                Segment 20090128: Total Size 507K, Allocated 260K, Free 243K                         minimum free space 64K,                            Awaiting promotion = 0K, sweeps before promotion =10               Segment 21EDE100: Total Size 7K, Allocated 0K, Free 3K                         minimum free space 0K,                            Awaiting promotion = 0K, sweeps before promotion =2      Generation 1:  Total Size 308K, Allocated 110K, Free 189K                Segment 2070F0C0: Total Size 68K, Allocated 0K, Free 64K                         minimum free space 3K,                            Awaiting promotion = 0K, sweeps before promotion =4               Segment 200540A8: Total Size 240K, Allocated 110K, Free 125K                         minimum free space 0K, static      Generation 2:  Total Size 68K, Allocated 0K, Free 64K                Segment 20F1C640: Total Size 68K, Allocated 0K, Free 64K                         minimum free space 117K,                            Awaiting promotion = 0K, sweeps before promotion =4      Generation 3:  Total Size 30387K, Allocated 30247K, Free 128K                Segment 2010F0C0: Total Size 6144K, Allocated 6139K, Free 0K                         minimum free space 3K,                            Awaiting promotion = 0K, sweeps before promotion =10               Segment 20F2D6B8: Total Size 16066K, Allocated 15934K, Free 128K                         minimum free space 0K,                            Awaiting promotion = 0K, sweeps before promotion =10               Segment 20720138: Total Size 8177K, Allocated 8173K, Free 0K                         minimum free space 0K,                            Awaiting promotion = 0K, sweeps before promotion =10          Total Size 31616K, Allocated 30618K, Free 628K


title: Execute script when hard-disk's standby state changes (i.e. it spins up/down)

text: How can I execute a shell script when the standby state of a hard-disk (as reported by `hdparm -C /dev/sdx`) changes? If possible, I would like to avoid polling `hdparm` for changes.


title: Expanding variables in zsh

text: The script below works in bash but not in zsh. I think it is because in the variable `OPTS`, I am "expanding" (not sure if this is the right word) the variable `$EXCLUDE`, and this syntax doesn't work in zsh. How would I replace that line to make it work on zsh?               SRC="/path_to_source"     DST="/path_to_dest"     EXCLUDE=".hg"       OPTS="-avr --delete --progress --exclude=${EXCLUDE} --delete-excluded"                                                         rsync $OPTS $SRC $DST


title: How to "set" this home network mesh up

text: I don't know much about networking security other than keeping unused ports closed is good. This is what I'm trying to accomplish: ![enter image description here](http://i.stack.imgur.com/Yg1iT.png) I need to be able to keep my server (the dotted line) with limited access to the Internet, but full access to the other devices on the network. I only want to have my home server connect to the net for updates (via `apt-get`) or for `wget`'ing some files sometimes. Is there a way to block the net off but let it by easily for software updates? I'm going to be running an apache web server from the server, but it should only be available to other devices on my network. I don't want someone being able to connect to it through the net. How can I do this securely? Basically I need a full web server accessible from my network but not from the internet (unless I specifically ask it to).


title: In MATE desktop, Right click context menu not as desired

text: I want to right click on a folder and easily open it in my favorite music player, say VLC. I have chosen "Other Application" and selected VLC and the option to "Remember" this selection. The folder then opens in VLC exactly as I would expect. But the option never sticks. It's just as seen in the screenshot: ![enter image description here](http://i.stack.imgur.com/QDXi6.png)


title: Shebang line with `#!/usr/bin/env command --argument` fails on Linux

text: I've got a simple script:               #!/usr/bin/env ruby --verbose     # script.rb     puts "hi"      On my OSX box, it runs fine:               osx% ./script.rb     hi      However, on my linux box, it throws an error               linux% ./script.rb     /usr/bin/env: ruby --verbose: No such file or directory      If I run the shebang line manually, it works fine               linux% /usr/bin/env ruby --verbose ./script.rb     hi      But I can replicate the error if I pack `ruby --verbose` into a single argument to `env`               linux% /usr/bin/env "ruby --verbose" ./script.rb     /usr/bin/env: ruby --verbose: No such file or directory      So I think this is an issue with how `env` is interpreting the reset of the shebang line. I'm using GNU coreutils 8.4 `env`:               linux% /usr/bin/env --version     env (GNU coreutils) 8.4     Copyright (C) 2010 Free Software Foundation, Inc.     License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.     This is free software: you are free to change and redistribute it.     There is NO WARRANTY, to the extent permitted by law.          Written by Richard Mlynarik and David MacKenzie.      This seems really odd. Is this a common issue with this version of `env`, or is there something else going on here that I don't know?


title: Moving /boot and MBR to a new drive

text: I have a CentOS 6 server with two hard drives in it. My old 3TB drive has been giving me some issues so I'm moving things over to a new drive. Because my `/` and `/home` partition are managed by a LVM it was easy to migrate those to the new drive. Now I want to move over my `/boot` partition and the MBR that makes it all start up. I loaded up a live CD and `rsynced` over my `/boot` partition to the same size partition on my new drive. I also tried to copy over my MBR with the following commands:               dd if=/dev/sda of=mbrbackup bs=512 count=1     dd if=mbrbackup of=/dev/sdb bs=446 count=1      After doing this I rebooted, told my BIOS not to look at the old hard drive during the boot cycle and only look at the new drive but all I ended up with was a blinking cursor. Did I miss a step here? Or is there something else I need to do to make things boot so I can completely remove my old drive? EDIT: I'm starting to think rsync was not the way to copy the /boot partition from one drive to another. Based on this guide, I tried using the dump command instead. In this command I copied my old, unmounted boot partition to my new, empty, mounted boot partition.               dump -0f - /dev/sdaX | (cd /mnt/boot; restore -rf -)       I'm getting a grub error 15 on boot which is better than a blinking cursor but I don't know if that is any closer to a solution.


title: File damaged/lost during transfer?  Recovery possible?

text: I was at uni a few days ago when I attempted to cut and paste a 500Mb file (a 3gp video recording) into my H drive on one of the uni network's Linux (Debian KDE 3.5) computers. I did not see any error messages indicating the cut-and-paste job had failed, but when I looked at the resulting pasted file, it appears now as a 60Mb file (that's a 440Mb discrepancy!). My file was somehow shrunk! Did the file get broken up in the process of pasting it and this is the fragment of an incompletely copied file? I suspect what happened was the file transfer was interrupted due to H drive size-allocation limitations imposed on users by administrators. But you'd think Linux would anticipate that the file was bigger than would be possible to move to the intended destination and abort the transfer _before_ it begun, not wait till it reached some forbidden limit then cancel discretely without notifying me. Also in the event of an interrupted file transfer, one normally expects the original file to be remain intact (i.e. not deleted) the original USB drive? The file appears in the destination, but is now much smaller and is non- functional. The original file in the source location on the external drive has disappeared, suggesting the job was completed successfully. This resizing is rather bizarre and now I don't seem to have access to the original file. After cutting and pasting the original may have been removed from it's source location. The computer has mishandled this task, apparently causing me to lose my file, and I would like you to help me to retrieve my file. I have tried recovering the file on my phone's SD card using PhotoRec and Sleuthkit forensic tool. No luck. Deleted sections of the disk may have been overwritten by new data. So zero progress on the source end. Any way to recover on the destination end (i.e. my uni network)?               peter@peter-deb:/media/E0FD-1813$ cd DCIM/     peter@peter-deb:/media/E0FD-1813/DCIM$ cd ..     peter@peter-deb:/media/E0FD-1813$ cd LOST.DIR/     peter@peter-deb:/media/E0FD-1813/LOST.DIR$ ls     peter@peter-deb:/media/E0FD-1813/LOST.DIR$ ls -a     .  ..     peter@peter-deb:/media/E0FD-1813/LOST.DIR$


title: Launch R code from within vim-r-plugin as separate window instead of inside tmux/screen?

text: I use the `vim-r-plugin` to write `R` code in `vim`. It is a nice plugin and I love that the plugin lets me run code directly from within `vim`. However, the `R` prompt is opened in a console which is attached to `vim` using `tmux` and the `vim` screen plugin. This limits my choices when it comes to window management. I would prefer if the `R` console was in it's own window so that my window manager (awesome) can handle the windows separately. Is there any way to do this? I would be satisfied if it was possible to pop out a running terminal from `screen`/`tmux` to run in it's own window using some shortcut.


title: Ubuntu 12.04LTS becoms slow and jerky randomly for a mintue and then becomes normal by itself

text: I am using Ubuntu 12.04LTS on my Toshiba satellite L510 and I have only Ubuntu installed. The system becomes slow and jerky by itself after every 10minutes or so and the remains like that for less than one minute


title: Make diff Use Full Terminal Width in Side-by-Side Mode

text: Most applications are smart about using the full width of the terminal available to them. My shell does, screen, vim, etc. However, `diff` in side- by-side mode (`-y`), does not. This angers me. It uses 126 character width, which is not even half of my 270 block width terminal. Looking through the man page does not reveal anything particular about automatically adjusting the width, only manually specifying it via `-W`. Is there perhaps a "hidden feature" of `diff` to allow it to automatically expand to the full width of the terminal? Or; What is the easiest path to automatically inserting `-W <terminalsize>` into my diff command whenever I run it? I am under the assumption that automatically appending -W to everything couldn't hurt anything, because it will only ever mean "use $x columns", which is always what I want, whether I'm in side-by-side mode, or otherwise.


title: Reading a directory in shell script

text: I want to read a numbered directory which is under a path, into a variable in shell script. The paths are something like this:               .../releases/R1/...     .../releases/R2/...     .../releases/R3/...      Each time that the script is executed I want to read the latest numbered R (R3 in this case) directory into a variable and then pass this as an argument to some functions inside the script. How shall I do that?


title: How to mount squashfs (embedded-linux) on Ubuntu?

text: I have tried to mount a filesystem from a firmware (embedded-linux) but it failed on my Ubuntu 12.04 machine. Could you tell me how to mount that file system? (or possible reasons of the failure). Details are as follows. ## Details Step1) Analyzing the firmware using binwalk shows starting address of squashfs filesystem. Thus I generated squashfs filesystem using "dd" linux utility. Step2) The analysis of generated filesystem using "binwalk ./fs.img" command shows:               Squashfs filesystem, big endian, lzma signatrue, version 3.0, size: XXXXXXX bytes, XXX inodes, blocksize: XXXXX bytes, created: xxxx      Step3) "mount -o loop ./fs.img ./fs" failed. "dmesg | tail" shows:               SQUASHFS error: Can't find a SQUASHFS superblock on loop1      How can I mount that file system? FYI, I installed latest squashfs-tools with lzma support from "sourceforge.net/procjects/squashfs".


title: Understand file descriptors and nodejs

text: I'm having a bit of a confused time understanding what a file descriptor is and if I even need one! I am trying to spawn a process in nodejs and have its out put be written directly to an out put file. I understand my question is specific to a language outside the scope of the unix family but I believe my problem is coming from me not understanding some thing about the system and not the language. This is the function I am calling from my script. I assumed I could call it in such a way               require('child_process').spawn('./my_script.bash 1>out.txt')      No luck though! I know that the script is executing and that its working.