0
votes
0answers
5 views

moving a (file | directory) while avoiding filename collisions

I have a bash script that moves files from a number of different locations to a folder named completed. I want to avoid overwriting previous files, so in the case when the name of a file (for ...
0
votes
0answers
1 views

How to disown and output to /dev/null every GUI application?

Is the any way to make every GUI application to be disowned and produce no output? Some configuration which would interpret: firefox as: firefox &>/dev/null & disown But it would ...
0
votes
1answer
4 views

For a given directory, how do I concatenate the tail end of recently modified files to a new file?

In case there's a better solution to the problem, my goal is to be able to quickly analyze ALL recent apache activity in /usr/local/apache/domlogs. The usefulness of this is when the server load is ...
0
votes
0answers
2 views

Select drive partition table in preseed file automated Debian install

I am using a preseed file for my Debian installs. I am using 1TB drives, and I would like to use MS-DOS partition tables. It is defaulting to GPT. Is there a way to choose which type of table to ...
0
votes
0answers
7 views

relation between chmod and sudo on an executable file

what are the relations between chmod and sudo on an executable file for a user? For an executable file, If chmod set it to be without execution permission for a user, must and can that user run the ...
0
votes
1answer
16 views

cat /dev/null emptied my log file but size did not change

I'm quite new to Unix. Using Solaris 10 I faced the below issue. There is a large log file with size 9.5G. I tried to empty the file using the below command. # cat /dev/null file_log.txt By doing ...
1
vote
0answers
8 views

Hide Vim fold characters

When using Vim to write prose my folds look like this: + # Section A expanded | Lorem ipsum dolor sit amet, consectetur adipisicing elit, | sed do eiusmod tempor incididunt ut labore et dolore magna ...
1
vote
1answer
11 views

notify-send not working under ssh

Maybe this is answered somewhere else, but I didn't see it. I am running Ubuntu 14.04. When I SSH into my machine, for example: ssh <user>@<machineip> notify-send "Hello" I don't see ...
0
votes
0answers
12 views

What are differences between directory order and alphebetic order with `ls`? [duplicate]

What are differences between directory order (-U) and alphabetic order (by default) with ls? They return the same order of a dir's contents to me.
0
votes
0answers
5 views

After Logoff from any user getting black screen

Presently I'm suffering a new problem. When I log-off my Linux system from any profile it's showing a black screen (graphical view has gone). After that I'm not able to login graphically. If I ...
1
vote
2answers
11 views

Know which terminal to use to execute commands depending on Linux in Java program

I am writing a platform independent Java console tool and within which will have to execute some commands in separate independent terminal at runtime. However, I need to know which terminal should I ...
0
votes
1answer
14 views

Question regarding forks and wait()

I am reading a textbook called "Linux Programming Interface" by Michael Kerrisk and there's a piece of code and creates children depending on command-line arguments and then waits for its termination. ...
0
votes
3answers
13 views

waiting for network in a bash script

I'm running a script that relies on network being up and a network share be mounted. The script runs on login (which happens automatically after boot). The problem is that by the time the script runs, ...
0
votes
0answers
4 views

Communication between two kernel drivers

I have custom embedded hardware i'm working on which runs linux. I've implemented a spi kernel driver to handle spi access to a eeprom which is exposed to userspace. Now i have another kernel driver ...
1
vote
0answers
4 views

Get OpenSSL FIPS Module Version Number

Is there a way for a user to determine what version of the FIPS module was compiled into OpenSSL? When I say "as user", I mean is there some functionality buried in the command line interface to get ...
2
votes
1answer
24 views

How to pipe a remote file to stdout over scp or sftp?

Using ssh, it is easy to print the contents of a file using ssh host 'cat file.txt' When ssh is disabled, and only SFTP is enabled, running the previous command gives the following error: ...
0
votes
2answers
26 views

List files of certain type under a dir?

If you want to list just directories (in the present directory) use ls -d */ What if you want to list just ordinary files, just executable files, or just soft links, or files of any other type? ...
1
vote
3answers
23 views

Command to 're-apply' previous command?

Is there an easy way to re-apply a previous command to a new command line entry? Say I typed in chmod u+r,g+x file.txt but forgot the sudo. Could I simply type sudo <some easy symbol>'? ...
0
votes
0answers
8 views

'xorg.conf' and hybrid graphics

Is there any sane way to be able to configure X server and have working hybrid graphics at the same time? Whenever I add "xorg.conf" X server stops loading driver for second (discrete) GPU. ...
1
vote
0answers
32 views

How to create CSV file without unnecessary spaces

I use the xls2csv binary in order to translate XLS doc to CSV in my linux red-hat machine, example: ( from man page ) xls2csv -x "1252spreadsheet.xls" -b WINDOWS-1252 -c "ut8csvfile.csv" -a UTF-8 ...
0
votes
0answers
15 views

I may or may not have broken grub during a sudo apt-get upgrade [on hold]

I'm very new to ubuntu and server administration as a whole, so please forgive my ignorance. I just did sudo apt-get upgrade and a gui came up saying something like this A new version of ...
1
vote
0answers
10 views

Real vs Actual memory in Xymon/Hobbit

What is the difference between real and actual memory usage in xymon ?
2
votes
2answers
26 views

Why is NetworkManager package name upper case?

All other software packages are lower case, so why NetworkManager upper case?
0
votes
1answer
12 views

Upgrading Linux (Fedora) with LUKS encrypted volume

I have FC18 on a LUKS/dm-crypt encrypted hard disk. I'd like to upgrade the system via a FC20 dvd. I looked around a bit and it seems that upgrading the system via the installation procedure from the ...
2
votes
0answers
11 views

Get notified from avahi

After looking for a zero-conf browser valid implementation I realised that inside my linux machine (ubuntu) I already have avahi and typing: avahi-browse -alr I get a complete list of all devices ...
0
votes
0answers
27 views

How to I create a file with a sorted list from users that have mail

I need to create a file ~/you have mail, it needs to contain a sorted list of all users on my local system which currently have mail in their "Inboxes" (i.n., their spool of delivered but no yet read ...
0
votes
0answers
7 views

Why absolute symlink on SAMBA share is followed directly by CIFS mount?

If an SMB share has a symlink with an absolute path /share/latest/dir -> /share/data/201407 then Windows clients can access files by link with no problem. dir \\smbserver\share\latest\dir\ ...
0
votes
0answers
8 views

Inherit environment variables in systemd Docker container

I have a Docker container running systemd. I want to pass environment variables to applications under it. When I start systemd from within Docker (/sbin/init as command line), Docker exposes ...
0
votes
1answer
8 views

big-scale tracker alternative for server filesystems

I'm using 8tb RAID storage (XFS filesystem) filled witch lots of files. By default Suse had installed tracker for file indexing/searching but: It's constantly reading HDDs (like for half a year now ...
0
votes
0answers
16 views

Why does “Connection Failed: 2002” display randomly on my PHP/MySQL website?

I'm running CentOS 6 with Apache/PHP/MySQL. PS. I'm sort of a novice at Linux, but I did my best to gather info before coming here. I'm now a bit stuck. I recently upgraded PHP to version 5.5.12. I ...
0
votes
0answers
6 views

Playback of valid file aborts in Exaile

I have a FLAC music file that, according to > flac -t file.flac flac 1.2.1 ... file.flac: ok is valid. Nevertheless, Exaile (and Rhythmbox) abort playback a few seconds in. MPD happily plays ...
-1
votes
1answer
23 views

Is %a an option of stat?

Usage: stat [OPTION]... FILE... Display file or file system status. -L, --dereference follow links -f, --file-system display file system status instead of file status -c ...
0
votes
0answers
21 views

how can I backup and restore of partitions and logical volumes?

This is my disk scheme sda1 /boot ext4 sda2 /somefiles ext4 sda3: lvm volgroup1/lvolume1 / ...
2
votes
0answers
14 views

Which network services depend on the “accept related input” iptables rule?

Background I am setting up a firewall for a webserver and was wondering if it would be a good security meassure to even reject RELATED input traffic and only except established connections by ...
0
votes
0answers
14 views

Inotify notifies only single change

I set the inotify_add_watch to watch /dev/disks. The entries in this directory are: by-id and by-uuid. When I plug-in a pen-drive, this directory gets added with two more directories: by-path and ...
-6
votes
2answers
44 views

How to you create directories and set permission? [on hold]

How do you create three directories in /storage named campaigns, financials, and public. Also, I'm wondering how to set the file access permissions as follows: campaigns – marketing group has full ...
0
votes
2answers
17 views

add bracket across numbers at only end of each line

I have a file having lines as: ram_reg_10/raja_reg_9/raghu_reg_8 abc_reg_4/bcd_reg_5 cad/pqr_reg_91 I want to convert string "_reg_number" into [number] at only last of every line in vi ...
0
votes
0answers
9 views

What processes on CentOS6/RHEL regulates user login but not password itself?

I was doing some maintenance via root account over ssh after several months of inattention. I shutdown, after startup I can't log in to root account at tty or via ssh. Fortunately, sudo works to ...
1
vote
1answer
23 views

Is Android compatible with the Linux Standard Base?

Moved from Stack Overflow, where I realize it was off-topic since it was asking for sources - far as I can tell, the rules forbid that there but not here. I know that the kernel in Android is now ...
1
vote
4answers
38 views

Combining sed statements

Let's say my input file looks like: ID1 1 5 6 8 ID2 1 4 5 7 I'm trying to formulate a loop that can combine these actions: If the line begins with a letter: keep the '\ n' after ...
0
votes
0answers
18 views

AIX equivalent of Solaris' iostat -E

On Solaris you can use the command iostat -En to view "disk error statistics" as counted by the kernel since the last reboot, where the -n option causes iostat to show "nice" device names. I'm ...
0
votes
0answers
11 views

Cross driver communication through sysfs or /dev/

I have two drivers I'm developing. One needs information from the other. Is there anything wrong with one driver reading from the sys attribute / or read/write through /dev/drivername of the driver it ...
1
vote
0answers
19 views

fail2ban not working

I have several services running on my Ubuntu 12.04 server and set up fail2ban, but it doesn't block the attacking IPs. SSH is running on port 22. jail.conf [DEFAULT] bantime = 600 maxretry = 3 ...
4
votes
4answers
133 views

How to split long sed expression into multiple lines?

sed 's/[long1][long2]/[long3][long4]/' file.txt I would like to split this command onto multiple lines - f.x. something like this: sed 's/ [long1] [long2] / [long3] [long4] /' ...
6
votes
5answers
267 views

What's wrong with this sed expression?

$ echo "104_Fri" | sed 's/^\([0-9]+\)_\([A-Za-z]+\)$/\1;\2/' 104_Fri I would like to match the digits at the beginning and the letters at the end - each as a group. Afterwards I want to output the ...
0
votes
1answer
15 views

Why does creating a ZPool result in this error?

When I try to create a ZPool, the following error occurs: user@arch ~ % sudo zpool create -f -o ashift=12 -m /data media raidz /dev/disk/by-id/ata-ST2000DM001-1CH164_Z2F0TL8V ...
4
votes
3answers
259 views

How can I test if a variable is empty or contains only spaces?

The following bash syntax verifies if param isn't empty: [[ ! -z $param ]] For example: param="" [[ ! -z $param ]] && echo "I am not zero" No output and its fine. But when param ...
2
votes
1answer
20 views

Is using shorthand quick substitution of history expansion problematic?

In my terminal (bash 3), I sometimes use the quick substitution ^aa^bb^ ^string1^string2^ Quick substitution. Repeat the last command, replacing string1 with string2. Equivalent to ...
2
votes
0answers
37 views

A window asking me to enter my ssh passphrase is popping up randomly. Why?

I'm on Ubuntu 14.04. For a few weeks now a small window keeps popping up randomly, grabbing my keyboard and asking me to enter the passphrase for my ssh key. The Window's title says "OpenSSH", and it ...
3
votes
1answer
20 views

Is it possible to change what tty a terminal emulator is connected to?

If I have a terminal emulator (say, xterm) by default it connects to a pseudoterminal like /dev/pts/3 What I would like to know is if it is possible to connect it directly to, say, tty1? Could I ...

15 30 50 per page