0
votes
1answer
12 views

tar: backup before overwriting

The cp command has a feature not well-known to everybody that it can backup before overwriting the target file. Does tar has such feature as well during restoring? I saw an option of --backup, but ...
39
votes
11answers
7k views

What is the relationship between Unix, Linux, Ubuntu and Debian?

What is the relationship between Unix, Linux, Ubuntu, and Debian? I suspect they are all Operating Systems that are based upon one another - similar to how Windows is based on DOS. Is my suspicion ...
0
votes
0answers
13 views

Very simple, single-user, hardcoded password FTP server for ubuntu

I have just mounted a Ubuntu box and would like to quickly spin a really simple FTP server that gives access to this server to upload the files. I just need a single user and I can create the password ...
1
vote
0answers
20 views

Edit bootable img file on mac OSx

I have downloaded a bootable image of ubuntu (7.95Gb .img file) for a Parallella (minicomputer), but its too big to fit on my 8 Gb micro sd card (which actually is only 7.8 Gb!). I would like to ...
0
votes
1answer
48 views

Cannot change directory into home directory, although permissions are set correct

I guess I need some help from an advanced Unix user... On a Ubuntu System I did something stupid. I typed sudo chmod 774 .* or the like, in a subfolder of my home folder and then I suddenly could not ...
0
votes
0answers
12 views

Message queue doesn't exists any more after reboot/shutdown of the virtual machine (Ubuntu)

I'm working on a simple multithread client/server program in C using native message queue of unix to send messages from one client to another. It works fine, but my problem is that after a reboot or ...
1
vote
1answer
45 views

how to create ubuntu installable iso image from files

this might be a quite silly question but I lack linux knowlege so here it is... I have an ubuntu VPS from which I need to create a development environment under my WMWare. So I wonder if the ...
2
votes
1answer
123 views

sed, insert file before last line

The following inserting file method for sed used to be working, even before last line, but not any more. Is it a bug in the current sed? Demo of inserting file method with sed: mkdir /tmp/test ...
0
votes
1answer
41 views

Can I restore a Unix server by copypasting system directories from a backup?

I messed up a Ubuntu server with lots of installed binaries, settings, etc. I'm going to have to reinstall Ubuntu, but I have a complete backup, hidden files and all, though not bootable. I'm hoping ...
1
vote
1answer
50 views

Find last 24 hours executed commands per each user in bash

How can I find last 24 hours executed commands per each user and mail them the result? I have Ubuntu GNU/Linux. I find out that I need a package named 'acct'. I have already installed and enabled that ...
0
votes
2answers
146 views

which unix or linux command is used to change root password of remote machine(Just an IP address) without using SSH Login

which unix or linux command is used to change root password of remote machine(Just an IP address)? Suppose I just have an IP address of the target machine which is on my network, But I do not know ...
0
votes
0answers
32 views

stop user from being runing any commands, should able to run only granted with sudo

Is there any single command or script which gives result, the list of how many commands a linux user is able to execute? And how to stop user from executing even a linux basic commands and should not ...
1
vote
0answers
30 views

Difference between Virtual Console and Workspace?

Please explain all differences between Virtual console and Workspace in Linux. If possible also kindly requested to specify definition and/or example. Many thanks.
1
vote
1answer
82 views

How to find available man chapter/section for a particular command? [duplicate]

For example: ls command have only chapter 1. while mkdir command have chapter 1 & 2. Is there any command which shows how many chapters are available for a particular command? [root@localhost /]# ...
1
vote
0answers
17 views

Difference between ntsysv and system-config-services

Please someone can guide the difference between: # ntsysv # system-config-services ntsysv - tune services should be automatically started, is it similar to chkconfig?
2
votes
3answers
46 views

Difference between service off and service stop?

Please can someone explain differences between service stop and service off: for example: # service httpd off # chkconfig httpd off
2
votes
4answers
176 views

/etc/rc.d what does rc stand for? [duplicate]

Do anybody have idea about full form of rc.d at? /etc/rc.d It contain scripts to is used to control the starting, stopping and restarting of daemons. But what exactly meaning of rc here, do ...
0
votes
2answers
90 views

Connect to the right serial port in Unix

Background I'm trying to connect to a device using UART though a micro-USB cable and GNU screen from Ubuntu and OSX. On both Ubuntu and OSX I can get the most recent serial connection with the ...
0
votes
1answer
312 views

gnuplot not working on ubuntu

My initial problem is that i am unable to find png as list of terminals in set term. So using the link http://askubuntu.com/questions/393882/png-terminal-in-gnuplot, I installed the gd library.And ...
0
votes
1answer
146 views

Unable to plot png in gnuplot

i need to plot png files in gnuplot 4.6.3 and/or 4.6.4.I am unable to do so as set term does not list "png" as an option. system information is Linux masterx-Studio-1535 3.5.0-27-generic #46-Ubuntu ...
1
vote
1answer
90 views

How to create an operating system on top of Ubuntu 13.10

I want create an operating system the way Mac did, building a program on top of a Unix operating system. I am planning to make a small operating system with a small amount of functions using C. I do ...
1
vote
2answers
2k views

Ubuntu : This does not look like a tar archive

I am trying to run the following command after I have downloaded a tar file using the sudo wget command to install CasperJS on our Ubuntu box. sudo tar -xvf casperjs.tar This does not look like a ...
1
vote
2answers
88 views

How to use 2x$$ together linux

the questing is how to use two variables togheter.. ex. $1,$2,$3 are set numb=2 I need to use command: head $$numb that must be the same as: head $2 I tried everything, I need to know what ...
0
votes
1answer
66 views

shell changing and login into ubuntu system

I have loggined into ubuntoo system using username-root and password-root. after running some commands i run chsh -s /bin/csh root to change its shell. but next time when i tried to logging into ...
0
votes
1answer
84 views

Can't remove a directory

I'm trying this: rm -fr /app/foo But getting error message: rm: cannot remove `/app/foo': Is a directory What I'm doing wrong?
1
vote
2answers
150 views

Convert ls -ld to chmod/chown commands

X home dir permissions: drwxr-xr-x Y home dir permissions: drwxr-x--x So my question is, how can i convert drwxr-x--x to a chmod/chown command so I can put the same permissions that Y has on his home ...
0
votes
1answer
668 views

Linux kernel source not found

I downloaded the source code of a driver (tun 1.1) and i was planning to installing when i obtained the following error: root@sergiosaturn-HP-Pavilion-dv6500-Notebook-PC:~/Documentos/Tese/tun-1.1# ...
1
vote
3answers
72 views

Is there a log of the output of startup commands?

While Ubuntu is starting up, the init rc commands are run. Is there a way to see their full output after the system has started?
1
vote
2answers
766 views

Using Piping with cat and less to concatenate 2 files

I'm fairly new to Unix commands and I just have a simple question. One exercise I'm working on wants me to use piping along with cat and less to concatenate 2 directories (in this case /etc/passwd ...
16
votes
3answers
1k views

How can I remove a file or directory called “\”?

I'm using terminal on a Ubuntu machine and there is a file that I would like to delete. The file's name is \ (just a backslash). Now usually I would just do rm filename However if I do rm \ then ...
0
votes
3answers
2k views

Change owner of the root folder and subfolders (Ubuntu 13.04)

I accidentally set owner of root folder (/) and all subfolders to one user by command $ sudo chown -R 'userName' /* Now I wanna set owner back to root user by command $ chown -R root:root /* But ...
4
votes
1answer
219 views

Edit a file through an on-the-fly encryption stream in Unix

Okay this is a weird sort of question. I might get down-voted for being stupid here. I'd like to be able to edit an encrypted file, but without having to manually decrypt it to a location on the ...
2
votes
3answers
1k views

How long do temporary files made with mktemp last?

I was wondering how long temp files created with mktemp last. It seems strange to me to rely on a file that could disappear at any time. I'm on ubuntu, if it matters.
2
votes
2answers
120 views

how to pass a flag as an argument to grep

I'm trying to pass -- as an argument to grep because the file I'm interested in contains -- within its text, like so grep -- file.txt but I cannot because grep sees -- as a flag. How do I pass -- ...
0
votes
1answer
22 views

Built installation usb key from linux virtual machine

I have a virtual machine I'd like to install as real os on my machine. As I have refit installed on my macbook air (Mac os, windows and ubuntu), I tried the clonezilla methode in order to overwrite ...
1
vote
2answers
220 views

Delete users who havent logged in for x days

got the simple code below USERS=`cat /etc/passwd` for USER in $USERS do echo "---------- $USER --------------" last -n 4 $USER done I want to ideally remove all users who haven't logged in ...
0
votes
1answer
39 views

Create a logging program

I want to create a program that logs all the processes started by the user and confirms after they are started. I don't want to log all the syscalls and other daemon processes. I have initially ...
0
votes
1answer
112 views

Revert Unix installation to fresh install

Let's say I have a fresh install of a Unix variant (Ubuntu, for instance), then I install different packages and edit some config files (php.ini, nginx.conf, etc.). Now say I want to revert Ubuntu to ...
0
votes
1answer
68 views

Automating setting up a Unix server

I have some various questions regarding setting up a Unix server, and how to do this smoothly: I just installed Ubuntu in Virtual Box on Mac. It struck me that you have to sit by the machine and ...
1
vote
2answers
253 views

scp command creating a copy in the remote machine itself

The command I am using to copy a file from remote to my local machine is as follows: scp root@IP_OF_MY_REMOTE_MACHINE:/home/sqldump.sql ~ So I am copying from /home directory of remote machine to ...
3
votes
1answer
99 views

How much RAM I could reduce [closed]

I'm renting VPS hosting where cost is based on RAM. Currently, i'm renting 4G. However, I wonder if I could reduce it to 2GB safely or even 1GB if possible. here my output of: "free -m" when server ...
0
votes
2answers
730 views

Which command is used to run or execute .exe files and movie files in linux?

I want to run movie files or executable file in linux. Which command is used run these two filetypes?
0
votes
2answers
2k views

How to make daemon starts automatically? Ubuntu server 12.04

I have nginx and postgresql daemons installed. How can make them start automatically every time server is started? I think to add sudo service nginx start sudo service postgresql start to ...
0
votes
3answers
61 views

Extra file with Same Name Created Automatically while writing a program in unix

Some time while writing a program for example convert.c a file with same name followed by tiled(~) convert.c~ gets created in same directory. why is this so and whats really happening .please explain ...
0
votes
2answers
1k views

Add color palette for Sakura terminal

How can add my own color palette in Sakura terminal? I use Ubuntu 12.04, and in options menu, I see only tango, Linux, xterm and rxvt palettes available.
1
vote
1answer
557 views

Installing .egg file for NLTK

I want to install NLTK on Ubuntu, and I'm following the instructions for UNIX here: http://nltk.org/install.html In step 2, I downloaded the egg file. Then I ran sudo sh setuptools-0.6c11-py2.7.egg ...
1
vote
1answer
118 views

Tail -f with pagination

I am trying to tail file with pagination tail -f foo.txt | more This works fine until file gets lets say 200 lines injected, when this happens nature of tail command is to go to end of file, at that ...
2
votes
0answers
477 views

MySQL crashes when connecting from localhost with tcp (UNIX sockets work)

I have Ubuntu 12.04 running MySQL server 5.5.24. I can connect with mysql --user root -p. status shows me : ... Connection: Localhost via UNIX socket ... When I try to connect with mysql --host ...
1
vote
1answer
141 views

Get PS1 evaluated value, or shell prompt value

I am trying to find the command that would return me evaluated value of $PS1 variable or just shell prompt with current path. e.g. foo-user@bar-pc:~\bar I would like to avoid using something like, ...
8
votes
3answers
13k views

Can files deleted with rm -rf be recovered?

When I delete folders or files in through osx terminal using the rm -rf, where do they go? I heard that some say they are deleted directly, but some also say it only "remove the link to the file ...