_id
stringlengths
1
6
title
stringlengths
14
150
text
stringlengths
17
32.6k
110557
Force ssh to not to print warnings
Is there a way to avoid ssh printing warning messages like this? "@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r", "@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @\r", "@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r", Although the remote host identity has changed but I know it is fine and just want to get rid of this warning.
143889
How do I make apt pick a certain package from a specific source?
I tried pinning the `debian_testing` source, but it's not really working (I want to pick version 0.10.29): Package: nodejs Pin: release a=debian_testing Pin-Priority: 1000 Here's the `apt-cache policy`: $ apt-cache policy nodejs nodejs: Installed: 0.8.1-1.1+0.0.0.6.a0dcf45.5 Candidate: 0.8.1-1.1+0.0.0.6.a0dcf45.5 Package pin: (not found) Version table: 0.10.29~dfsg-1 1000 150 http://debian.mirror.iweb.ca/debian/ testing/main amd64 Packages 0.8.1-1.1+0.0.0.6.a0dcf45.10 1000 150 http://debmirror/squeeze/ unstable/main amd64 Packages 0.8.1-1.1+0.0.0.6.a0dcf45.6 1000 150 http://debmirror/squeeze/ testing/main amd64 Packages *** 0.8.1-1.1+0.0.0.6.a0dcf45.5 1000 600 http://debmirror/squeeze/ stable/main amd64 Packages 100 /var/lib/dpkg/status 0.6.19-1.1+0.0.0.5.9ae19bd.9 1000 150 http://debmirror/squeeze/ unstable/main amd64 Packages 0.6.19-1.1+0.0.0.5.9ae19bd.5 1000 150 http://debmirror/squeeze/ testing/main amd64 Packages 0.6.19-1.1+0.0.0.5.9ae19bd.4 1000 600 http://debmirror/squeeze/ stable/main amd64 Packages 0.6.19-1.1+0.0.0.4.b58cc24.3 1000 600 http://debmirror/squeeze/ stable/main amd64 Packages 0.6.19-1.1+0.0.0.3.4de0c44.2 1000 600 http://debmirror/squeeze/ stable/main amd64 Packages 0.6.19-1.1+0.0.0.2.f68c674.1 1000 600 http://debmirror/squeeze/ stable/main amd64 Packages What's missing to make it pick the 0.10.29 version from `debian_testing`?
11542
Desktop Actions and mime types for a DRM file format
I want to handle a DRM file format, which adds an encryption wrapper outside of the protected content. Please see the diagram. # _**___ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ ____** # | DRM wrapper MIME | # | **___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ ____** # | | Embedded content MIME | | # | | ** ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ ___**| | # | ** ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __**| I also write some media applications for it. But every DRM-ware applications can support only a few embedded content MIME types. For example, a DRM-aware music player can only support DRM-protected or clear songs while a DRM-aware picture viewer can only support protected or clear pictures. So how can I write the .desktop entry of such DRM-aware applications? If I set MIME type to the DRM wrapper MIME type, my music player may be launched to open a DRM-protected picture and fails. And because the embedded content can be various while the wrapper MIME type is unique, I can expect many such failures. Is there any better practice to handle this issue? Is it feasible to invent new MIME types that mix the wrapper MIME type and the embedded content type? E.g. audio/mpeg-xx- secured or image/jpeg-xx-secured and using them in the .desktop entry of my DRM-aware applications? Great thanks! Amanda
89373
SARG with no records found
I want to use sarg tool in linux centOS to report users using website. But when installed, and when Iuse command `sarg -x -z`, the output is: SARG: Init SARG: Loading configuration from /usr/local/etc/sarg.conf SARG: TAG: access_log /var/log/squid/access.log SARG: TAG: output_dir /var/www/html/squid-reports SARG: TAG: date_format e SARG: TAG: overwrite_report yes SARG: Parameters: SARG: Hostname or IP address (-a) = SARG: Useragent log (-b) = SARG: Exclude file (-c) = SARG: Date from-until (-d) = SARG: Email address to send reports (-e) = SARG: Config file (-f) = /usr/local/etc/sarg.conf SARG: Date format (-g) = Europe (dd/mm/yyyy) SARG: IP report (-i) = No SARG: Input log (-l) = /var/log/squid/access.log SARG: Resolve IP Address (-n) = No SARG: Output dir (-o) = /var/www/html/squid-reports/ SARG: Use Ip Address instead of userid (-p) = No SARG: Accessed site (-s) = SARG: Time (-t) = SARG: User (-u) = SARG: Temporary dir (-w) = /tmp/sarg SARG: Debug messages (-x) = Yes SARG: Process messages (-z) = Yes SARG: SARG: sarg version: 2.3.1 Sep-18-2010 SARG: Reading access log file: /var/log/squid/access.log SARG: Records in file: 0, reading: 100.00% SARG: Records read: 0, written: 0, excluded: 0 SARG: No records found SARG: End And this is /var/log/squid/ root@FW sarg]# ll /var/log/squid/ total 184 -rw-r-----. 1 squid squid 0 Jul 25 03:49 access.log -rw-r----- 1 squid squid 12592 Jul 14 03:16 access.log-20130714 -rw-r----- 1 squid squid 208 Jul 25 03:49 access.log-20130725 -rw-r-----. 1 squid squid 6944 Sep 3 12:56 cache.log -rw-r-----. 1 squid squid 1286 Aug 4 03:37 cache.log-20130804.gz -rw-r-----. 1 squid squid 168 Aug 11 03:22 cache.log-20130811.gz -rw-r----- 1 squid squid 929 Aug 18 03:48 cache.log-20130818.gz -rw-r----- 1 squid squid 1285 Aug 25 03:41 cache.log-20130825.gz -rw-r----- 1 squid squid 1301 Sep 1 13:24 cache.log-20130901.gz -rw-r--r--. 1 root root 6517 Jul 25 08:51 squid.out -rw-r-----. 1 squid squid 13968 Sep 4 13:56 store.log -rw-r----- 1 squid squid 32398 Aug 4 03:37 store.log-20130804 -rw-r----- 1 squid squid 32592 Aug 11 03:22 store.log-20130811 -rw-r----- 1 squid squid 30652 Aug 18 03:48 store.log-20130818 -rw-r----- 1 squid squid 6180 Aug 25 03:41 store.log-20130825.gz -rw-r----- 1 squid squid 5763 Sep 1 13:24 store.log-20130901.gz And this is `sarg.conf` access_log /var/log/squid/access.log output_dir /var/www/html/squid-reports overwrite_report yes ..... and reports in web My Squid User Access Reports FILE/PERIOD CREATION DATE USERS BYTES AVERAGE 24Jul2013-24Jul2013 Wed 24 Jul 2013 03:04:28 PM ICT 1 5.57K 5.57K 21Jul2013-25Jul2013 Thu 25 Jul 2013 09:30:37 AM ICT 0 0 14Jul2013-25Jul2013 Thu 25 Jul 2013 10:35:22 AM ICT 1 5.57K 5.57K Generated by sarg-2.3.1 Sep-18-2010 on 25/Jul/2013-10:35 This is very little information. How can I increase that?
11544
What is the difference between /opt and /usr/local?
According to the Filesystem Hierarchy Standard, `/opt` is for "the installation of add-on application software packages". `/usr/local` is "for use by the system administrator when installing software locally". These use cases seem pretty similar. Software not included with distributions usually is configured by default to install in either `/usr/local` or `/opt` with no particular rhyme or reason as to which they chose. Is there some difference I'm missing, or do both do the same thing, but exist for historical reasons?
89378
Everything works in the auto-generated kickstart file for installing centos-linux except for selecting target drive + boot dot
I discovered that if I copy the auto-generated kickstart file in CentOS Linux, I could re-install CentOS Linux without having to fill stuff, and so on.. It appears centos saves the auto-generated kickstart file to `/root/anaconda- ks.cfg` Let's see what it looks like: # Kickstart file automatically generated by anaconda. #version=DEVEL install harddrive --partition=UUID=94A9-D1AE --dir=/ lang en_US.UTF-8 keyboard us network --onboot no --device eth0 --bootproto dhcp --noipv6 network --onboot no --device wlan0 --bootproto dhcp --noipv6 rootpw --iscrypted $6$wWTsHJyQ8Fe88fWk$v6u7X.WanDxPm26FJCi9gCwWXlwRg9tQze25uGk150W4BHLKcGRkcgFn4lRGowrXl1C0LlBQCOLxR9sx3Rjw20 firewall --service=ssh authconfig --enableshadow --passalgo=sha512 selinux --enforcing timezone --utc America/New_York bootloader --location=mbr --driveorder=sda,sdb --append="crashkernel=auto rhgb quiet" # The following is the partition information you requested # Note that any partitions you deleted are not expressed # here so unless you clear all partitions first, this is # not guaranteed to work #clearpart --all --drives=sda #volgroup VolGroup --pesize=4096 pv.008002 #logvol / --fstype=ext4 --name=lv_root --vgname=VolGroup --grow --size=1024 --maxsize=51200 #logvol swap --name=lv_swap --vgname=VolGroup --grow --size=7840 --maxsize=7840 #part /boot --fstype=ext4 --size=500 #part pv.008002 --grow --size=1 #part None --fstype=efi --label="LIVE" --onpart=sdb1 --noformat repo --name="CentOS" --baseurl=hd:UUID=94A9-D1AE:/ --cost=100 %packages --nobase @core %end To make this work better, I simply added interactive right above the `install` line on top. so that I can see what it is doing. Looks like it didn't auto fill the root-password. so let's remove the encrypted password and add a plain text password and then test again. Looks like it didn't select "use all space" So let's uncomment the commented lines towards the bottom portion. Looks like there are errors, I was forced to quit installation and reboot. Here is a final version that works okay. Only some lines were uncommented, and root password was changed to plain text. it is now Use All Space during the installation proces. I also added `interactive` line to it. # Kickstart file automatically generated by anaconda. #version=DEVEL interactive install harddrive --partition=UUID=94A9-D1AE --dir=/ lang en_US.UTF-8 keyboard us network --onboot no --device eth0 --bootproto dhcp --noipv6 network --onboot no --device wlan0 --bootproto dhcp --noipv6 rootpw aaaaaa firewall --service=ssh authconfig --enableshadow --passalgo=sha512 selinux --disabled timezone --utc America/Los_Angeles bootloader --location=mbr --driveorder=sda,sdb --append="crashkernel=auto rhgb quiet" # The following is the partition information you requested # Note that any partitions you deleted are not expressed # here so unless you clear all partitions first, this is # not guaranteed to work clearpart --all --initlabel part /boot --fstype=ext4 --size=500 part None --fstype=efi --label="LIVE" --onpart=sdb1 --noformat repo --name="CentOS" --baseurl=hd:UUID=94A9-D1AE:/ --cost=100 %packages --nobase @core %end Everthing works great but it is not selecting the target hard drive, and placing a dot into the Boot thing. In other words the final step has to be done manually by hand. What should be done so that it can select the target drive and also ensure selected as the boot drive ?
110552
ksyts problem firing up GUI
i set my display export DISPLAY=CQIST097417W.msad.ms.com:0.0 loaded module module load syb/kerberos and kicked off ksyts ksyts but got the error : application-specific initialization failed: couldn't connect to display "CQIST097417W.msad.ms.com:0.0" invalid command name "option" while executing "option add *cursor $sytsConfigDB(cursor,$sytsConfigDB(cursor,current))" invoked from within "if { $isGuiSyts } { option add *cursor $sytsConfigDB(cursor,$sytsConfigDB(cursor,current)) option add *Text.height 4 option a ..." (file "/ms/dist/syb/PROJ/syts/4.24/dba/bin/../scripts/syts.tcl" line 6361) ANYONE ANY IDEA HOW TO FIRE UP THE ksyts GUI PLS ? john
11549
Howto set access control lists ACLs in OpenLDAP
I'm using the Debian Squeeze OpenLDAP. Where can I set ACLs? Isn't it possible to execute the access to directives with `ldapmodify`? There's no `slapd.conf` file in Debian, they use a `slapd.d` folder
5988
How can I check the charge of an Apple iPod Shuffle?
I am using Ubuntu and would like to know the answer to this question: * How does one determine whether his/her Apple iPod Shuffle's charge is full in Linux? In Windows it's easy since iTunes shows the charge. But in Linux neither Rhytmbox nor gtkpod shows the battery charge. Any help regarding this.
110550
What is the difference between red5 RC1 and RC2?
What is the difference between the red5 versions RC1 and RC2 ? and what does RC mean?
5982
What tools to use to eliminate metadata in graphics files?
What tools can I use to delete all the EXIF, IPTC, XMP, etc metadata from graphics files?
5980
How do I insert a space every four characters in a long line?
I've got a long line that I want to insert a space every 4 characters, on a single lone line of solid text to make it easier to read, what's the simplest way to do this? also I should be able to input the line from a pipe. e.g. echo "foobarbazblargblurg" | <some command here> gives foob arba zbla rgbl urg
5987
How to control the list of locales which are generated by APT?
Each time I install or operate in other means l10n-related packages, the APT system "rebuilds" a lot of English locales, which takes considerable time. Look at the APT log: Configuring language-pack-en-base (1:10.10+20100930) ... Generating locales... en_AG.UTF-8... up-to-date en_AU.UTF-8... up-to-date en_BW.UTF-8... up-to-date en_CA.UTF-8... up-to-date en_DK.UTF-8... up-to-date en_GB.UTF-8... up-to-date en_HK.UTF-8... up-to-date en_IE.UTF-8... up-to-date en_IN.UTF-8... up-to-date en_NG.UTF-8... up-to-date en_NZ.UTF-8... up-to-date en_PH.UTF-8... up-to-date en_SG.UTF-8... up-to-date en_US.UTF-8... up-to-date en_ZA.UTF-8... up-to-date en_ZW.UTF-8... up-to-date Generation complete. And this happens for each package. I don't need all those variants - most of the time I use non-English locale altogether. For me `en_US` and `en_GB` would be sufficient. So my questions are: * Are all those `en_*` variants really installed on my machine? How to check that? * If they are, how to cleanly remove them and prevent APT from generating them?
116667
dmesg filled with audits every minute from cron
My `dmesg` is filled with output of like the following, starting from a couple of seconds after booth and continuing indefinitely: [ 3155.216230] type=1006 audit(1393236841.859:85): pid=4206 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=84 res=1 [ 3214.742935] type=1006 audit(1393236901.406:86): pid=4227 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=85 res=1 [ 3274.960017] type=1006 audit(1393236961.646:87): pid=4245 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=86 res=1 [ 3335.143342] type=1006 audit(1393237021.853:88): pid=4266 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=87 res=1 [ 3394.290920] type=1006 audit(1393237081.024:89): pid=4325 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=88 res=1 [ 3454.269891] type=1006 audit(1393237141.024:90): pid=4344 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=89 res=1 [ 3514.802667] type=1006 audit(1393237201.575:91): pid=4424 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=90 res=1 [ 3574.320552] type=1006 audit(1393237261.119:92): pid=4441 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=91 res=1 [ 3634.364982] type=1006 audit(1393237321.187:93): pid=4498 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=92 res=1 [ 3694.503761] type=1006 audit(1393237381.347:94): pid=4559 uid=0 old auid=4294967295 new auid=0 old ses=4294967295 new ses=93 res=1 This is caused in part by cron. If the root `crontab` includes `* * * * * echo test`, the audits appear once a minute. If it is empty, no audits appear. Why does this happen? How can I stop it? **Edit** : I'm running an updated Arch Linux. Trying to find the process that causes the audits: $ systemctl -a | grep audit -i auditd.service not-found inactive dead auditd.service
2677
Recovering accidentally deleted files
I accidentally deleted a file from my laptop. I'm using Fedora. Is it possible to recover the file?
145152
Recover deleted files on Raspberry Pi?
So I just rm -rf'ed a folder with a few files I need. Yes I know I should've had a backup, but it's just a Pi. It's designed to be played around with! Is there _anything_ I can do to recover that folder? Would the files be cached somewhere? Can you recommend any Linux file recovery programs? I don't want to boot into the SD again as it might write over the data :( Help! EXT4 filesystem.
63470
Recover files from ext3 formatted external hard drive
> **Possible Duplicate:** > Recovering deleted files on fedora I have an external hard drive that I had been using to store some photographs, but I accidentally installed Lubuntu on it. I'd like to know if there's any way to recover the files from it. I the drive was FAT32 beforehand; I'm not sure, though. It was a Seagate FreeAgent GoFlex (1 TB) Anway, I can't use any of the recovery tools I found, because they can't scan EXT filesystems from Windows. I'm running a dual-boot, Windows XP and Ubuntu, plus I frequently boot into Puppy Linux from a USB drive, so it really doesn't matter which OS it's for. (No Mac-only software, though.) Anyway, it's really important that I get these photos back.
114843
How to recover deleted directories "/home/pi"
I just deleted my `/home/pi` directory while I was trying to remove the directory under `/home/pi` which was `/home/pi/nmap`. So, is there anyway to recover `/home/pi` directory as I have other important directories under it. I use the commmand: rm -rf /home/pi
101237
How to recover files I deleted now by running rm *?
By mistake I ran rm * on the current directory where I created many c program files. I had been working on these since morning. Now I can't take out again the time that I spent since morning on creating the files. Please say how to recover. They aren't in recycle bin also!
104174
Recover directory structure + files
## Background: I had a dual boot of Windows + Linux Mint. Mint didn't feel right to me, so I decided to install Ubuntu to replace Mint. I booted from a Ubuntu Live USB and started the installer. The installer asked me if I wanted to replace Linux Mint. I did, so I chose that option (big mistake). It then proceeded to format the drive and install Ubuntu. After I booted into Ubuntu and discovered this, I quickly shut the computer down and began to work from a separate PC, hooking up PC #1's drive as a secondary to PC #2. ## Desired outcome: I would love to have all my files back - in their original directory structure and with their original file names. ## What I've tried: Primarily, I've tried two tools: **R-Linux** and **EaseUS Data Recovery Wizard**. R-Linux was able to recover what appeared to be most files (at least those that were of the file types R-Linux searches for by default). I was able to open and view these files (every file I opened; I didn't try all considering the number). However, R-Linux did _**not**_ recover the directory structure or filenames - only the files, sorted by file type and with random file names. E-DRW appeared to recover the files, filenames, and the directory structure. However, the same files that I was able to open/view when recovered by R-Linux appeared corrupt when recovered by E-DRW. JPG files (in multiple viewers) would not open. PHP, txt, and doc files all failed to open. I feel that considering one tool was able to recover file names and directory structure, and another tool was able to recover the file contents, that my goal is reachable. However, neither of these tools appear to be able to reach it completely. ## My question: Is there another tool I should/could try, or have I exhausted my options? I have access to both a Linux (Ubuntu) and Windows system, so exclusive tools are not a problem. ## Response to duplicate flag: I do not believe this question is a duplicate. As I stated previous, I am able to recover files using R-Linux but not the meta data. The file names and directory structure are vital to the success of my efforts, as most of the files I desire to recover are useless/meaningless without this information.
88608
Undo file removed by rm commend on MAC terminal
I unfortunately deleted `.bash_profile` file from my MAC. Accidentally I typed `rm .bash_profile`. Now how can I get my file back?
75088
Getting back rsync's deleted files
I accidentally rsync-ed to a server using the delete attribute when I shouldn't have. Is there any chance of getting the data on the server that rsync removed.. back?
154989
How to Recover Data in LINUX MINT Quiana
Can I recover deleted files in LINUX MINT 17 Quiana. I have deleted my folder containing data with shift+delete. Now, I want my data back.
48253
I ran rm -rf. Need to recover files
> **Possible Duplicate:** > How to recover a file just deleted > How to undelete/restore the deleted files in ubuntu linux I ran `$rm -rf` on a machine by mistake. But it wasn't as a super-user, so only my home directory is lost, however I need to recover the files. After the command was executed, I ran no more commands and instantly shut down the machine to prevent any data from being overwritten. I am currently running the machine through a live-disk. Can anyone help me recover the lost files? If it's any help, I am running Arch-Linux.
153087
Recover file from previous installation?
I recently wiped an old ubuntu server of mine and installed debian, but i forgot to backup a very important file. I know there is a chance that the computer has already wrote over the file, but what can I do to look for this file?
90186
How do I simply recover the only file on an empty disk just deleted?
Usually, the best way to recover a deleted file is to have backups and that, if the backup failed, you should immediately remount the drive read-only. (See this thread: How to recover a file just deleted ) But in some occasions, if the deleted file wasn't that important, it just would save some time to just "undelete" it. Is there a simple way I could try on bash for the case that the deleted file on an **ext4 filesystem** was **the only file on the disk** , especially, if the disk is not used otherwise?
18685
How to recover a file just deleted
I just deleted a file in Nautilus with Shift+Delete, which warned me that "If you delete an item, it will be permanently lost." I wonder if there is no way to recover the file? My OS is Ubuntu 10.10. Thanks!
108860
Recover deleted Directories in centos
How can we recover deleted directories in CentOS 64 bit. I have tried it with `test-disk` but unable to update. Can anyone let me know the solution?
21196
How to undelete/restore the deleted files in ubuntu linux
> **Possible Duplicate:** > Recovering deleted files on fedora > undelete files from local fileserver I accidentally did rm * in a directory instead of another directory from console in a Ubuntu11 machine.is there any way to recover these files.
144389
Recover an overwritten file
I had a linux plain text document file with close to 100000 lines, a size of 10 Mb. I accidentally overwrote the file via python code. But I got an exception in the middle of the code and think the file socket did not get closed properly. The new file has a few new lines (250) ,BUT the size of the file corresponds to the old one. I was wondering if the old content will still be there within the file and any chances of recovering the same. I tried using TestDisk and poked around a little bit. But it did not have any option for working on a particular file or maybe I am doing it wrong. I dont have any expertise in file systems and would really appreciate any pointers on how to proceed. Thanks
98778
rm -rf /home/ Recovery
OS :-Suse Linux Enterprise 12.0 File System :- ext3 I hit `rm -rf /home/`, immediately I did `Contol`+`C` so the command got canceled but until that time I lost ~9GB of data from this `/home` dir. I don't have System GUI access. Please suggest a suitable recovery command or packages so that i can recover my lost `/home` files. I just want to recover only one lost dir from this `/home` dir that is, `/home/cubot/etl/script`. This `/home/cubot/etl/script` was having some important scripts and it is not visible now completely.
123255
Restore deleted Mysql Directory in linux
My MySQL directory has been deleted from directory /root/var/ by mistake, we need to restore it, Is it possible ?
80270
Unix/Linux undelete/recover deleted files
Is there a command to recover/undelete deleted files by `rm`? $ rm -rf /path/to/myfile How can I recover `myfile`? If there is such a tool how can I use it?
90387
How to recover: Deleted accidently important files
I've accidentally deleted today the `/var/www` with 2 Joomla-Homepages on it. Is there any possibility to recover all these files? I'm using PhotoRec right know, but the recovered files are named like: f3411984.html I have not create backups, which I should have. I there a better way to recover these files.
20639
Restore overwritten /usr/local/bin
> **Possible Duplicate:** > Recovering deleted files on fedora I accidentally overwrote my `/usr/local/bin` directory when installing something. Is there a way I can restore this directory? What can I do to get Ubuntu functional again?
14952
undelete files from local fileserver
I have a NAS (mybook world white light) in my living room where all my music and stuff is stored. I've mounted the music folder of the nas in the local music folder of my home directory on my desktop computer. My fstab entry looks like this: //192.168.2.222/Public/Shared\040Music/ /home/simon/Musik/ cifs credentials=/home/simon/.smbcredentials,defaults 0 0 A few minutes ago, I moved my home directory on my local desktop computer with the help of this (german) tutorial. At first everything looks great, but then I realised that my music folder was empty. I think I deleted everything in this step during the tutorial: umount /home rm -rf /home/* Because the music folder was still mounted to `/home/simon/Musik :/` Is there a possibility to recover something of the data? As I realized what happened, I shut down the NAS.
127479
su to another user using ssh keys?
Assuming that `user_A` and `user_B` set up and exchange public ssh keys with each other, is it possible for `user_A` to `su` into `user_B` on the same machine?
127478
What is the difference between invoking a perl script via sh or perl
I have a simple Hello World perl script. #!/usr/bin/perl print 'Hello world.'; It works fine if I run it via `perl <file_name>`, but it fails I run it via `sh <file_name>`. My understanding of the first line is that it invokes the perl shell (similar to #!/usr/bin/bash will invoke a bash shell). So what exeactly is the difference between the two commands? I found this thread http://ubuntuforums.org/showthread.php?t=1133334 that states `sh <file_name>` "In that case, you don't run Perl at all, but the shell, which will call the program 'print'." IF that's the case is the #! just being interpreted as a comment. If so, is it needed at all? (I am aware that I can chmod +x the file and run it dirrectly, but I just want to know the difference between the two methods I was using)
103541
Automount CIFS shares on boot?
I have a script saved that mounts my CIFS share, but I have to run it manually every time I boot into Linux and I connect to the internet. Is there a way that I can set the script to run as root every time Linux boots, and have it continually run until it connects to the drives? I'm running Linux Mint. **UPDATE:** I already have the package installed. I have a working script to mount it: #!/bin/sh mount -t cifs //xxx.xxx.xxx.xx/usb1-1share1 /media/Private -o username=xx,password=xx,domain=WORKGROUP mount -t cifs //xxx.xxx.xxx.xx/Uploads /media/Uploads -o username=xx,password=xx,domain=WORKGROUP
127471
Using awk for data manipulation
I have an input file in the following format. #track chr11 61731756 61735132 FTH1 - chr12 6643584 6647537 GAPDH + chr11 18415935 18429765 LDHA + chr12 21788274 21810728 LDHB - chr22 24236564 24237409 MIF + chr4 6641817 6644470 MRFAP1 + chr15 72491369 72523727 PKM - chr10 73576054 73611082 PSAP - chr2 85132762 85133799 TMSB10 + chr13 45911303 45915297 TPT1 - I want to get an output file in which if the 5th column is + then subtract 5000 from column 2 and add 2000 to column 3 so as to output following chr11 18410935 18431765 LDHA + chr2 85127762 85135799 TMSB10 + If the 5th column is "-", then add 5000 to column 3 and subtract 2000 from column 2 so as to get following output chr11 61729756 61740132 FTH1 - chr12 21786274 21815728 LDHB - So I want the output to be in the same order as input. Also I want to output the first line #track as it is. I want to do this in awk. How can I perform this. I am new to awk and still learning. Thanks
82440
Where would I find where an .htaccess file is located and being used on a Mac OS X Lion server that sets Basic Auth on an Apache server?
I've installed some software, namely, a continuous integration (CI) server (Jenkins) on a Mac Mini running Lion Server. The server, by default, runs from port 8080 on local host via the url: `http://localhost:8080`. However, when I try to access the page it seems to be protected by Basic Auth and it asks me for a name and a password. Granted, I never set that Basic Auth and I've been told I can remove the authentication and use that port for the CI server. However, I'm hard pressed to find an `.htaccess` file anywhere that sets the Basic Auth? If it's not set in an `.htaccess` file then where would Basic Auth be set?
103547
Emacs won't open file in Bazaar repository
I have a Bugzilla installation, and am trying to open `/Bugzilla/Install/CPAN.pm` using emacs. However, I get this error when attempting to do so: Searching for program: no such file or directory, bzr As I am kind of unfamiliar with `emacs` beyond the basics, and very unfamiliar with `perl`, I have no idea what this means. Why do I get that message? Why won't `emacs` load the file? How do I fix this problem? If any additional info is needed, I will be happy to oblige. EDITS: I am trying to open it with the command `emacs Bugzilla/Install/CPAN.pm` while in the `bugzilla` directory. ![enter image description here](http://i.stack.imgur.com/wt8Kl.png)
127474
How to check whether a usb Wifi supports Hotspot or not
I found a wifi card here:- Wifi Now, how can I check whether It can enter master mode and have support for hotspot? As my current in-built Wifi card is giving me this:- Error for wireless request "Set Mode" (8B06) : SET failed on device wlan0 ; Invalid argument. On executing:- sudo iwconfig wlan0 mode master I am seeing `SoftAP` in its heading. Should I assume that I will go in master mode on my linux box?
120120
Escaping dash in `dch` call
I'm using `dch` to modify the changelog for a debian package that is being built using some bash script. The messages for changelog are taken from some data source and are just passed to `dch --append`. And today I noticed that it fails to do its job if starts with dash (`-`) character: $ dch --append "- when" Unknown option: Unknown option: w Usage: dch [options] [changelog entry] Run dch --help for more details How would one properly escape such a string?
120122
Bare-bones linux?
I am working on a homemade OS and I was originally going to write it myself in Assembly and Python, but I decided that doing this would just be easier, faster, and more Linux-y. I have the Python part done, I just need to do the Linux part. So, I was wondering if you had any idea of a place I could get a pre-made ISO of any (preferably Debian based) Linux distro, with BASH, Aptitude, Python 2.7.6, and crontab installed, and with NO xorg or xvesa or whatever. It would also be extremely helpful if instead of posting links to places without a proper explanation and what-not, if you could just give me a download link.
146541
How to stop gnome from forcing me to logoff / logout?
From time to time my Gnome 3 shell or some parts of it are crashing. Gnome sees a time out and is forcing the user to logout **without** other possibilities. _"Oh no! Something has gone wrong."_ See superuser for a screenshot. (Fail whale is providing this dialog.) Is there a way to stop gnome from doing that? Since the other programs are still running and working fine... In my case its clearly a time out, since a scientific analysis eats up all memory and after its done Gnome has a hard time to recover. (I experienced also these crashes, when I was using some (combination of) extensions which are buggy. In that case the probably only or best solution is to not use those extensions... also considering the posts I've read about this.)
120124
dkms versus module-assistant
`module-assistant` has been the de-facto method of compiling and building binary Debian packages containing kernel modules for a while now. More recently a comparable utility has appeared - `dkms`. If anyone has experience using both, please do a compare and constrast on the advantages and disadvantages of using one versus the other. One item to address in an answer is whether `dkms` builds binary Debian packages for kernel modules too, and if so, how, and if so, what the differences between the packages built by `m-a` and `dkms` are, if any. I have personally never used `dkms`, but I have used `module-assistant` sporadically over many years, and it has been a good experience. I don't have immediate plans to experiment with `dkms`, so I don't think I am the right person to write an answer. Random googling found a discussion here, also this. Needless to say, any answer should be based on first hand experience, not copying from web forums. A worked example using both would be nice. Possibly `nvidia-kernel`, since that is quite commonly used. Yes, I know it is a proprietary kernel module. :-( UPDATE: Thanks to jordanm for his answer. I'd like something that goes into a little more detail about what is going on under the hood, for both `m-a` and `dkms`, though I did not initially mention this. Also, it sounds like most of the time `dkms` will work transparently and automatically. But what are the failure modes of `dkms`. How do they both cope with manually compiled/installed kernels? Either installed from a binary package or a local install.
110558
"su" with error "X11 connection rejected because of wrong authentication."
As root, I'm connecting to a remote host to execute a command. Only "standarduser" has the appropriate id-file and correct .ssh/config, so I'm switching the user first: su standarduser -c 'ssh -x remotehost ./remotecommand' The command works fine, but despite the fact that I used "-x" (disable X11-Forwarding) and having X11Forwards disabled in `/etc/ssh/ssh_config`, I still get the error message: X11 connection rejected because of wrong authentication. I'm not getting the error message when I'm logged in as "standarduser". This is quite annoying as I would like to integrate the command in a cron job file. I understand that the error message refers to the wrong authentication of root's .XAuth file, but I'm not even trying to connect via X11. Why is "ssh -x" not disabling the X11 connection and throwing the error message? _UPDATE_ : The message only shows when I'm logged in within a screen, when using the command stated above on the local machine itself (without screen), I don't get an error message, so this should be fine with cron, too. I also started the same command with `-v` and surprisingly got the error message FIRST, even before the status information from SSH: root@localhost:~# su standarduser -c 'ssh -x remotehost ./remotecommand' X11 connection rejected because of wrong authentication. OpenSSH_6.2p2 Ubuntu-6ubuntu0.1, OpenSSL 1.0.1e 11 Feb 2013 This led me to the problem itself, it is NOT the `ssh` which is throwing the error message, it's `su`: root@localhost:~# su standarduser -c 'echo Hi' X11 connection rejected because of wrong authentication. Hi Why do I only get this error within `screen`? How can I disable this error message? (Update title)
82991
Bash is not finding a program even though it's on my path
I have a program on my path. The program runs when executed with a full path specified. But the program cannot be found when I run it with just its name. Essentially, I want to understand how the below output is possible, and how to fix it so that my program can actually be found without a full path specified: root:/usr/local/bin# ./siege **************************************************** siege: could not open /usr/local/bin/etc/siegerc run 'siege.config' to generate a new .siegerc file **************************************************** root:/usr/local/bin# echo $PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games root:/usr/local/bin# siege bash: /usr/bin/siege: No such file or directory root:/usr/local/bin# wtf!?!? I'm on Ubuntu 12.04 using bash. Also please note the warning output from siege is not relevant for the purposes of this question, as I am only interested in whether or not the program can be found and invoked.
82990
How can I grep for this or that (2 things) in a file?
I have a file that has "then"'s and "there"'s. I can $ grep "then " x.x x and then some x and then some x and then some x and then some and I can $ grep "there " x.x If there is no blob none some will be created How can I search for both in one operation? I tried $ grep (then|there) x.x -bash: syntax error near unexpected token `(' and grep "(then|there)" x.x durrantm.../code # (Nothing)
46139
Remove 50GB oldest files in busybox when used capacity reaches 95%
Ok i have requested a code here but initial i didn't ask to make it busybox compatible. My bad. I'm new to linux and coding. The code needs to do the following: > Delete 50GB of oldest data (dir with files) from a directory when the HD > reaches a capacity of 95%. The code they gave me is, that is not working with busybox: DIRS="a/ b/" MAXDELBYTES="53687091200" # 50GB DELBYTES="0" find $DIRS -type f -printf "%T@ %s %p\n" | sort -r -n | while read time bytes filename do rm -fv "$filename" DELBYTES=$((DELBYTES + bytes)) if [ $DELBYTES -ge $MAXDELBYTES ]; then break; fi done What is not working: * -printf (changed it to -print) * %T@ %s %p\n (dont know what to change it to) * Do not know what else isn't working. I'm new to coding and linux. Now this need to be translated to busybox so it will work on my embed linux system. Also a cron command needs to be added so it runs every Friday. Thanks for your support!
46138
Proxy software that will decide where to send requests for linux
Does anyone know of some proxy software that is easy to configure thus.... User makes a request Request is sent to clear internet. If website can not be found. i.e. is Blocked by ISP (China) then the same request is made to a VPN connection which is maintained.
46135
good Ubuntu/Debian distro for a development/coding VM?
I have a Windows laptop, but I like to use Linux as a development/coding environment. Currently I am currently running Ubuntu 12.04 as a guest OS with VirtualBox. Some of the issues with this setup are: * I need a lighter-weight distro - Ubuntu installs too many extraneous packages * I like to work in VirtualBox's "seamless" display mode - GNOME Terminal is the app I use the most. I'd like to find a window manager which gives me more vertical real estate. The GNOME desktop manager (the classic version) works pretty well, but I don't need the top menu bar or bottom task bar, and I could do with smaller title bars on windows. Any suggestions on windows manangers, configuring GNOME or other Debian/Ubuntu compatible distros?
53907
syncing two maildirs
I have a server that I use to frequently get email from Google using `offlineimap`. the email is stored in a maildir format on this server. What tool can I use to sync this maildir with the local maildir that is on my latop? I've tried `getmail` but that doesn't have a two-way sync. `syncmaildir` gave me headaches (kept crashing, plus has some strange dependencies on gtk). `rsync` seems too brutal. I need a simple tool that can be used over ssh to get new emails from the server, update the flags (read, etc) and delete deleted messages. What have you guys used so far? What are the perks of your proposed tools?
88399
How to generate signal interrupt on a file descriptor in Linux?
How can I generate a signal interrupt on a file descriptor in Linux? Motivation is to generate a interrupt in userland as we have in microcontrollers. I'll have file descriptor for I/O, and want to generate a interrupt whenever there will be a change in its status? Can someone tell me? If possible please give me example.
46132
Ubuntu password policy
I want to set the system-wide password policy on an Ubuntu 12.04 LTS server. Googling around, a lot of people point to this (very old) document: https://help.ubuntu.com/10.04/serverguide/user-management.html It says to edit the `/etc/pam.d/common-password` file and look for the `password required` line: password required pam_unix.so nullok obscure min=6 max=8 md5 To set the minimum password length, adjust the `min=` setting. However, on 12.04, my file looks like this (comments removed): password [success=1 default=ignore] pam_unix.so obscure sha512 password requisite pam_deny.so password required pam_permit.so Which line do I change? The one with `pam_unix.so`? Or the one with `password required`? Or is it now in some other file? There's nothing in that file's comments about setting the password policies.
46131
What does altering a file/directory mean?
From `man ntfsundelete` > Look for deleted files altered in the last two days > > > ntfsundelete /dev/hda1 -t 2d > I wonder what altering files/directories mean? 1. Does deleting some files/directories count as altering them? For example, if I created a file more than two days ago, and didn't change it until yesterday when I deleted. Will the command be able to recover it? 2. Does moving some files/directories from being under a directory to being under another directory count as altering them, even when the files/directories being moved have not been changed themselves? I am hoping to find a way to specify and undelete the directories (with files inside) that I deleted at once last time. Thanks!
46130
allow webalizer in selinux (centos)
I roughly followed these instructions: http://library.linode.com/web- applications/analytics/webalizer/centos-5 to install and configure webalizer to run on several VirtualHosts. Unfortunately when i try and run: `webalizer -n site.net -o /var/www/webalizer /etc/httpd/logs/site.net- apache_log` I get: `Error: Can't open log file /etc/httpd/logs/site.net-apache_log` But after running: `echo 0 > /selinux/enforce` It works. How can i tell selinux to allow webalizer to run? _EDIT_ [root@web-01 logs]# ls -lZ -rw-r--r--. root root unconfined_u:object_r:httpd_log_t:s0 access_log -rw-r--r--. root root unconfined_u:object_r:httpd_log_t:s0 error_log -rw-r--r--. root root unconfined_u:object_r:httpd_log_t:s0 tt.net-access_log -rw-r--r--. root root unconfined_u:object_r:httpd_log_t:s0 tt.net-error_log -rw-r--r--. root root unconfined_u:object_r:httpd_log_t:s0 ck.tt.net-access_log -rw-r--r--. root root unconfined_u:object_r:httpd_log_t:s0 ck.tt.net-error_log . [root@web-01 ~]# service --status-all auditd (pid 1132) is running... [root@web-01 ~]# /opt/webalizerScript.sh Error: Can't open log file /etc/httpd/logs/tt.net-access_log Error: Can't open log file /etc/httpd/logs/ck.tt.net-access_log [root@web-01 ~]# audit2allow -w -a <no matches>
73623
Does sed write to the file or give a sample output
when using `sed` with a file like this sed 's/a/o' fruits it gives the necessary output to the terminal but it does not change the contents in the file. How do I permanently change the file with the above substitution?
150175
Using bash's "source" command return error though it successfully read config file
I want my bash script to read parameters from config file. Here is what inside the script: #!/bin/bash source /home/myscript/conf/config.conf echo "$username" and below is my config.conf: username="jonas" The output when I run the script: [user@machinename bin]$ . thescript : No such file or directoryonfig.conf : command not found jonas Here I am confused, though it successfully print "jonas", why is there error "No such file or directory" and "command not found"? Am I doing something wrong?
97156
Gnome can't open Sound Mixer - No volume control GStreamer plugins and/or devices found
I'm trying to get sound output working on a VPS, but whenever I'm trying to open the gnome sound control panel as non-root, I'm getting the error "No volume control GStreamer plugins and/or devices found." Now I found several forum topics concerning this question, but even the proposed "sledgehammer" method in those, namely setting /dev/snd chmod to 777, did not work for me. I also tried adding my user to the audio group to no avail. I'm kinda helpless, since it working with root indicates a permission problem, but setting the permissions to 777 should fix that, right? Is there maybe something I overlooked, any more permissions I may have to set or is it a different problem alltogether? Some data about the VPS: * OS: Debian 6.0 Squeeze * Kernel: 2.6.32-028stab107.2 If you need any more information, let me know.
147413
gpg: Bad signature
I'm trying to sign a public PGP key but am encountering a 'Bad signature' error: gpg --edit-key someone@somedomain.com ... gpg> sign ... You need a passphrase to unlock the secret key for user: "My User <myuser@mydomain.com>" 2048-bit RSA key, ID 12345678, created 2012-01-01 I enter my passphrase then get: gpg: checking created signature failed: Bad signature gpg: signing failed: Bad signature gpg: signing failed: Bad signature I've done some searching online but can only find old, unrelated posts or ones relating to smart cards, which I'm not using. I'm running gnupg 2.0.25-1 on an Arch Linux box. Any help gratefully received!
19973
Is a file manager in Linux a necessity or a luxury?
I agree that this is a kind of a personal issue - to use a file manager or not in Linux, but I heard that it's also a bad practice to use a file manager especially for newbies because first of all they have to learn the shell and all file manipulations should be done from the shell. Is that true and do Linux users use file managers?
19972
Convert gnu screen status line to tmux status line
I am using the following screen status line, configured in my screenrc: ![screen status](http://i.imgur.com/qztsh.png) I configured it using the following line: hardstatus alwayslastline hardstatus string '%{= kG}[ %{G}%H %{g}][%= %{=kw}%?%-Lw%?%{r}(%{W}%n*%f %t%?(%u)%?%{r})%{w}%?%+Lw%?%?%= %{g}][%{B}%Y-%m-%d %{W}%c %{g}]' I did not create this theme, I don't remember where I found it, but I really like it. I am now converting my configuration to `tmux` and I can't seem to replicate this configuration in my `tmux.conf`. I got this far: set -g status-bg black set -g status-fg white set -g status-left '#[fg=green]#H' set-window-option -g window-status-current-attr bright set-window-option -g window-status-current-bg red Which produces this line: ![tmux status](http://i.imgur.com/wSvyi.png)] Please ignore the different hostname, it's on a different server What configuration can I use in `tmux` to produce a status line similar to the first one? Thank you!
127525
Data transfer between Ubuntu and CentOS
How do I transfer data between Ubuntu and CentOS using LAN cable, in the same network? I tried installing Samba which did not go well in CentOS.
19970
How to replace a list of placeholders in a text file?
I have a text (configuration) file, but the program that reads the file unfortunately doesn't allow using any kind of variables. So I'd like to use a preprocessor that replaces a set of placeholders in the config file before passing it to the program. I can define the format of the variables any way I want (e.g. `§SOME_DIR`). If I had just a few variables, I would probably use `sed`: sed -e "s*§SOME_DIR*$SOME_DIR*g" my.conf | target_prog But the list of variables is pretty long, and it should be easy to configure - so I'd prefer to put the variables in a properties file like SOME_DIR=... OTHER_DIR=... ... and then call some_replace_tool my.properties my.conf | target_prog I'm looking for "some_replace_tool". Any ideas?
102816
How do I make themes apply to windows as well as system elements?
I am using Linux Mint with Cinnamon. Whenever I install a theme, it changes the 'system' elements, like the menu and taskbar, but not the window borders or buttons or the like. I went on the 'Other Settings' tab in the 'Themes' window, but no options other than the ones that came with the system appear. Specifically, I want the Holo theme to be system-wide. Forgive me if this is a dumb question; I just started using Linux recently.
80598
ulimit & rlimit in Linux, are they the same thing?
I see people use the terms `ulimi`t & `rlimit` interchangeably, can I say they are referring to the same thing?
16705
Find out what processes are writing to hard drive
On my Lenovo T400 and Ubuntu, the light for hard drive writing keeps flashing. I was wondering if in Linux it is possible to find out what processes are doing I/O to the hard drive? Just like by `top`, you can find out what processes are using most CPU and memory.
279
Is there a pbuilder-like environment for RedHat?
I would like to know if is there any utility like Debian's `pbuilder`, to build RPM packages on RedHat using a clean environment (`chroot`). I've found mach which has support for something like this but under a Debian environment, and doesn't support RHEL. I need something that runs on RHEL 5.5.
19979
Splitting giant files into a specific number of lines
I have a CSV that is 40 000 lines long. What is the simplest tool to read from line x to line y? I am sure there are more professional ways to do it but I would just like a bash script that works in the form of readFile --from 10 --to 20 so that I can process ten lines, then call it again and bring in ten more lines. I was considering just using an AWK script but can you do it even more simply with something like `cat`, `grep`, `tail` or `head`?
80594
Trying to set keyboard layout using Xorg configuration but it's not working
I'm trying to set my HP Pavilion g6 keyboard layout to English(us) and Arabic(ara). I'm using Fedora 18, but followed Arch Wiki anyways. Here's my `90-keyboard-layout.conf` file : Section "InputClass" Identifier "keyboard" MatchIsKeyboard "on" MatchDevicePath "/dev/input/event*" Driver "evdev" Option "XkbModel" "pc105" Option "XkbLayout" "us,ara(qwerty_digits)" Option "XkbVariant" "qwerty_digits,qwerty_digits" Option "XkbOptions" "grp:alt_shift_toggle" EndSection I've entered `pc105` because I have no idea what's the corresponding `XkbModel` for my HP Pavilion g6 keyboard (looked in `/usr/share/X11/xkb/rules/xorg` but didn't find it). I have also this file `00-anaconda-keyboard.conf` which contains : #This file was generated by the Anaconda installer Section "InputClass" Identifier "keyboard" MatchIsKeyboard "on" Option "XkbOptions" "terminate:ctrl_alt_bksp," EndSection Section "ServerFlags" Option "DontZap" "false" EndSection Here's my `setxkbmap -print`: xkb_keymap { xkb_keycodes { include "evdev+aliases(qwerty)" }; xkb_types { include "complete" }; xkb_compat { include "complete" }; xkb_symbols { include "pc+us(qwerty_digits)+ara(qwerty_digits)(qwerty_digits):2+inet(evdev)+group(alt_shift_toggle)+terminate(ctrl_alt_bksp)" }; xkb_geometry { include "pc(pc104)" }; }; What else is missing? Layout switching is not working at all so far.
80593
Linux Mint 15 Doesn't detect Windows with update-grub
I just installed Linux Mint 15, but `update-grub` doesn't detect Windows: $ sudo update-grub Found linux image: /boot/vmlinuz-3.8.0-19-generic Found initrd image: /boot/initrd.img-3.8.0-19-generic Found memtest86+ image: /boot/memtest86+.bin No volume groups found done Video showing Mint 15 (ubuntu raring) update-grub error/bug
16700
What is the default shell for .sh in AIX?
I am fairly new to AIX machine. We would like to deploy some program into the AIX machine which is yet to come. We have a short experience in AIX machine and after login using putty, we felt the shell is very weird and some aspects compared to the Red Hat Linux we are using. The backspace is not functional, and some arrow key have weird behaviour too. Anyway, assume this is a healthy machine, I would like to ask, if we create a .sh file and execute it, what is the default shell for it? And what is the default shell after login?
16703
Mandriva 2007 Cannot setup printer
I tried to use a printer that is shared by a Windows PC. When I try to Mandrive Control Center > Hardware > Set up printer, the window opens but there is no content. Only a window. Seems that **`system-config-printer`** package is not installed. I try to open Software Management > Look at instalable ... and select All search by name _system-config-printer_ but the search returns nothing. What should I do next to be able to use the printer?
16702
.DELETE_ON_ERROR behavior with make and pipelines
The `.DELETE_ON_ERROR` target will tell make to delete a target if a rule fails. But this doesn't work for pipelines, because the exit status value `$?` holds the value of the last program in the pipeline. As an example, the following makefile will not delete the newly created file _foo_. .DELETE_ON_ERROR: foo: false | true > foo Is there a way to get make to consider the rule as having failed if any of the programs in the pipeline fail (i.e., if there's a non-zero value in any of the elements of the `$PIPESTATUS` array)?
12019
Creating a new partition in empty space between 2 existing ext4 partitions
Output of `fdisk -l`: Disk /dev/sda: 640.1 GB, 640135028736 bytes 255 heads, 63 sectors/track, 77825 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x07f2837e Device Boot Start End Blocks Id System /dev/sda1 1 13 104391 de Dell Utility /dev/sda2 * 14 1926 15360000 7 HPFS/NTFS /dev/sda3 1926 27578 206055449+ 7 HPFS/NTFS /dev/sda4 27579 77826 403610625 5 Extended /dev/sda5 27579 52921 203561523+ 83 Linux /dev/sda6 59000 59972 7811072 82 Linux swap / Solaris /dev/sda7 59972 77826 143407104 83 Linux A few things to note: 1) There's around 50GB of unallocated space betweed sda5 and sda6. 2) sda5 is mounted at `/` on my Ubuntu install, and sda7 is mounted at `/home`. I want to install Fedora in the unallocated space by creating a 50GB ext4 partition. I would create only a single root partition in that space without modifying any partition around, and I'll take care of all the GRUB mess. My question is: Will creating an ext4 partition between sda5 and sda6 change the sdaX numbering of the swap and /home partitions? I guess yes. In any case, will it also change the UUID of any other partition? I'm asking this because I can see in my ubuntu fstab that the partitions are identified by their UUID. If I just create a partition in the unallocated space and install Fedora, will the UUIDs change of the surrounding drives so much that the drives won't auto- mount at Ubuntu startup? Any help would be appreciated. Thanks!
88024
PDF viewer with reflow capabilities for linux?
Anyone know of a PDF viewer for linux that can reflow text on the fly? There are a few for android, and at least one for windows, but I haven't found any for Linux. **NOTE:** I'm doing this on a 1600x900 laptop. The resolution is not the problem, badly formatted PDFs with hard-to read wide columns is the issue I'm trying to get around.
12015
What is produced after using cat on an image?
Let's say one creates a file like so: touch myFile You enter some text in it with vim or whatever, and then use `cat myFile` to spit the contents out into the terminal. Now, what happens when I use cat on any image? Say, cat myPNG.png I just get a bunch of garbage. It just made me think about what the `cat` command is attempting to do, and where all of this "garbage" comes from. Just curious.
88029
IPTABLES chain need help for restriction
I have two network cards eth0:- 172.16.91.70 (External Zone) eth1:- 172.16.85.70 (Internal Zone) I have clients in my Internal Zone which can access the external network. The ping goes fine and can access external net. Now I want to restrict the access for the internal zone. The external zone connects to another network that is 172.16.81.0 and that connects to 172.16.79.0 Now I want my internal zone be able to access complete 172.16.91.0 network, drop packets from 81.0 network and access 79.0 network. But I also don't want it to access internet because the squid proxy server is in 81.0 network.
136793
Copying the newest files
We have a script running which picks up the report generated monthly on remote servers. I was trying to find a way to pick up the latest file from the remote servers only. Will find work in script or that's a bad practice? for host in "${hosts[@]}"; do scp "$host":"$remote_path" "$local_target_dir"/filename."$host" done File format = servername_BBC-3.0_2014-06-04_164510_.txt
12010
Why does installing Debian from DVD download many packages?
I know Debian is general purpose, so a Debian install could just as easily be a server as a desktop. It seems, however, that even with a DVD of disk1 from Debian, it is downloading a tremendous number of files from the network mirror. I would have thought a DVD would be enough to get a base desktop installation running. What am I missing here? Let me clarify: I chose "SSH Server" and "Desktop Environment" in tasksel. Is GNOME not a part of the primary installation DVD?
52468
Identical mount points for two file systems when installing Linux
So, I'm going through Crunchbang's installer (very similar to Debian's), and am at the partitioning step. I chose the 'Guided - use entire disk and set up encrypted LVM' method (usually I do manual without encryption). It wiped my disk, and I set my encryption pass phrase. So now this is my current partition configuration LVM VG $HOSTNAME, LV root - 242.7 GB Linux device-mapper (line #1 242.7 GB f ext4 / LVM VG $HOSTNAME, LV swap_1 - 7.1 GB Linux device-mapper (line #1 7.1 GB f swap swap Encrypted volume (sda5_crypt) - 249.8 GB Linux device-mapper (cry #1 249.8 GB K lvm SCSI1 (0,0,0) (sda) - 250.1 GB ATA WDC WD2500BEKT-7 #1 primary 254.8 MB B F ext2 /boot #5 logical 249.8 GB f crypto (sda5_crypt) SCSI5 (0,0,0) (sdb) - 16.0 GB JetFlash Transcend 16GB #1 primary 16.0 GB B fat32 The last entry is obviously the USB drive I've booted from, but I'm including it for completeness. I may have inadvertently done something to it. When I try to write changes to disk, I get the following error message [!!] Partition disks Identical mount points for two file systems Two file systems are assigned the same mount point (/): LVM VG $HOSTNAME, LV root and SCSI1 (0,0,0), partition #5 (sda). Please correct this by changing mount points.
153776
Is it possible to configure dynamic loader for an executable
I am looking for a way to allow an executable to find its shared library, but in order to avoid conflict with any package that could use a different version of the same shared library I prefer to keep these libraries in a 'private path' (not /usr/lib). The possible ways seems : * embbeded rpath in the executable * set LD_LIBRARY_PATH when executable is started * add libraries path in ldconfig configuration in a ld.so.conf.d file rpath links target structure to the build, ld.so.conf.d configure path for the system, LD_LIBRARY_PATH need the caller process to be aware of it. So I wondering if it is possible to use ld.so.conf.d (or similar loader configuration) applied only for an executable ?
153775
extract lines according to a particular column
I have a CSV file like CK,ck XYZ,xyz,xyzs ABC,abc,abcs PQR,pqr,pqrs LMN,lmn, IJK,ijk, I have to check if something is written in column 3 except whitespace, then display the whole line.the output will be: XYZ,xyz,xyzs ABC,abc,abcs PQR,pqr,pqrs
42084
Clock skews on remote machines
I am performing some experiments on a network of about 10 remote Linux computers which are geographically scattered. I suspect some of them have clock skews but they are seen transiently (eg. once in a week or twice in a month). I was wondering if there exists some tools which could detect and quantify such clock skews. Also wondering if clock skew is the right term for what I am witnessing or could it be called clock synchronization.
153773
cat a directories files apending the file name to the row of text and removing the header row?
How can I cat a directories files apending the file name to the row of text and removing the header row? So as to only have 1 header row in the all.txt file.
64671
SUID permissions - Which is correct?
Trying to secure a Linux server and have little experience with SUID. After executing find / -perm +4000 many programs were discovered. I have seen conflicting advice here and hereon what should be enabled and not. SUID Enabled ` /bin/su /usr/bin/passwd /usr/bin/gpasswd /sbin/unix_chkpwd ` SUID Disabled ` /usr/bin/crontab /usr/bin/newgrp /bin/ping /bin/ping6 /bin/umount /bin/mount /usr/bin/chsh /usr/bin/chfn /usr/libexec/pt_chown /usr/bin/sudo /usr/bin/sudoedit /usr/bin/chage /usr/sbin/userhelper /usr/sbin/usernetctl /usr/sbin/suexec` UNSURE `/usr/libexec/openssh/ssh-keysign /sbin/pam_timestamp_check ` Server will host multiple sites with few Linux / SFTP users. What should change? Also, how should I test?
114358
selecting a field when you cannot count from the start
I have a long file ( 20000+ lines) where each of the lines is a description of a book: book_number "title of the book" size type author_number Where the element in quotes is a string with quotes and the others are numbers, except for type which is a single word: 23446 Raising Steam 537724 EPUB 4 I want to extract all the size fields but using cut you cannot use negative numbers to count from the back of the result of splitting with `-d " "`: cut -d " " -f -2 books.txt I cannot count from the front as the books may have any number of spaces in the title (I did not make up this format, I would have used CSV or JSON which require quoting). Am I missing some option that allows using `cut`? What else could I use to get the second-before-last field with a one line solution?
52460
What tool can preview console font?
I don't know about the console font format, for a normal truetype font, I could use gnome-font-viewer to preview it, but what about console font? If I don't switch back to another tty, and use setfont command, is there a way to view it in X?
119867
How to burn iso to a CF card?
Slax Linux installation file is only available in .iso format. How to burn it to a Compact Flash card? It also uses KDE, I think GNOME 2 or MATE might be more light weight. I want to install it on a one board computer, namely a PC Engine ALIX board.
119866
How to search '(+1)' character substring in a string
I want to search for (+1) in a string (which is a GDG dataset name to confirm if it is a GDG) and want to get a binary answer if it has (+1) as part of the string or not. Can some one please help?
17254
How to set up properly zram and swap
I'm configuring & compiling new 3.0 kernel. One of the goodies I planned to use for some time (by patching) that was merged into 3.0 is zram. Is it possible to set both hdd swap and zram swap so the zram is used first and only spilled pages are put into actual swap?
17255
Is there a command to list all open displays on a machine?
When SSH'd locally into my computer (don't ask, it's a workaround), I can't start graphical applications without running: export DISPLAY=:0.0 If I run this first and then run a graphical application, things work out. If not, it doesn't work, there's no display to attach to. Is there a command for listing all available displays (ie: all possible values) on a machine?
52466
Copy files with permission 200
I want to recursively copy a directory, preserving file attributes, which contains a directory tree including some files that have permission 200 (i.e. `\--w-------`). The copy command `cp -ar sourcedirectory targetdirectory` skips those files, saying, for each one, something like this: cp: cannot open `sourcedirectory/foo/somefile.bar' for reading: Permission denied` **My question: without altering their permissions, how can I prevent the copy command from skipping those files?** _If you think I ought to use a utility other than`cp` in my copy command, please explain why._
17257
Weight-based block IO control for VMs
I use KVM to manage my virtual machines. I am trying to limit the resources provided for VMs. I am able to limit the CPU and memory allocated for VMs using libvirt/cgroups. Now I want to control the disk time allotted for each VM by applying some weights. I looked at blkio control from cgroups. Since VM is just a Linux process, I will be able to use cgroups but I am not sure whether it will work for asynchronous IO too. If not, can someone suggest a good alternative solution?
53739
How to parse options in a shell function to navigate multiple projects
I can use help with this bit of bash I am trying to write. The scripts purpose is to speed up my development while working with multiple projects. I labeled the parts that I have questions about in the code. # is there a way to persist this through working enviornments besides this? declare -x WORKING=`cat ~/.working` #alias p='builtin cd $WORKING && pwd && ls' alias pj='builtin cd $WORKING/public/javascripts && pwd && ls' function pp { echo `pwd` > ~/.working } # is there a way to close the scope of this function? function p { # how do I process flags here? # -f and -d etc. can exist but may not # either way I want $1 to be set to the first string if there # is one if [ -z "$1" ] then echo '*' builtin cd $WORKING && pwd && ls return fi BACK=`pwd` builtin cd $WORKING #f=`find . -iname "$1"` f=( `echo $(find . -type d -o -type f -iname "$1") | grep -v -E "git|node"` ) #echo ${f[1]} if [ -z "${f[0]}" ] then return fi if [ -z "${f[1]}" ] then # how can I write this as a switch? if [ -f ${f[0]} ] then vim ${f[0]} return fi if [ -d ${f[0]} ] then builtin cd ${f[0]} return fi else echo "multiple found" #for path in $f #do # sort files and dirs # sort dirs by path # sort files by path #done # display dirs one color # display files another color # offer choices # 1) open all files # 2) open a file # 3) cd to selected directory # 4) do nothing fi # nothing found builtin $BACK }
63023
Tell tcpdump to skip custom header
I have an IP packet with x bytes of custom header coming in on an interface. Is there a way to tell `tcpdump` or `tshark` to ignore the first x bytes and decode and display the IP packet? Any pointers would be helpful; I don't want to write a custom discector
53733
man gives the error about locale
I have $ locale LANG=en_GB.UTF-8 LC_CTYPE=ru_RU.UTF-8 LC_NUMERIC=en_GB.UTF-8 LC_TIME=en_GB.UTF-8 LC_COLLATE=ru_RU.UTF-8 LC_MONETARY=ru_RU.UTF-8 LC_MESSAGES=en_GB.UTF-8 LC_PAPER=ru_RU.UTF-8 LC_NAME=ru_RU.UTF-8 LC_ADDRESS=ru_RU.UTF-8 LC_TELEPHONE=ru_RU.UTF-8 LC_MEASUREMENT=ru_RU.UTF-8 LC_IDENTIFICATION="en_GB.UTF-8" LC_ALL= $ locale -a C en_GB.utf8 POSIX ru_RU.utf8 But `man` gives the error: $ man man: can't set the locale; make sure $LC_* and $LANG are correct What manual page do you want? If I set the `LC_ALL`, the error disappears: $ LC_ALL=en_GB.UTF-8 man What manual page do you want? But I don't want to set `LC_ALL` because I set some `LC_` to the other locale. How to solve this problem with `man`?
53730
Bash script for Angstrom
I have written a bash script to automate cross-compiling an OpenCV program: echo "Compiling started for: $1" if [[ $1 == *.c ]] then gcc -ggdb `pkg-config --cflags opencv` -o `basename $1 .c` $1 `pkg-config --libs opencv`; elif [[ $1 == *.cpp ]] then g++ -ggdb `pkg-config --cflags opencv` -o `basename $1 .cpp` $1 `pkg-config --libs opencv`; else echo "Only c or c++ files" fi echo "Output: ${1%.*}" But now I noticed that there does not exist a bashrc at the Angstrom distribution. So what can I do? Regards
README.md exists but content is empty. Use the Edit dataset card button to edit it.
Downloads last month
950
Edit dataset card