Unix is a multitasking, multi-user computer operating system originally developed in 1969 by a group of AT&T employees at Bell Labs.

learn more… | top users | synonyms

0
votes
1answer
50 views

In Linux/ubuntu hardy Apache2, how do I find where my default access logs and error logs are being kept?

I just installed Apache2 on my unix via aptitude. Where are the default logs kept?
2
votes
4answers
569 views

Cron not running my Python statement

I have the following entry in crontab: * * * * * python -c "import datetime; datetime.datetime.now()" >> /home/myname/pythoncron1.log The pythoncron1.log file is being created but has nothing ...
4
votes
6answers
10k views

How to check what port mysql is running on

On my windows dev box mysql is running on port 3306 How can I check what port it is running on the unix server that I have to upload the app to.
4
votes
2answers
107 views

ampersand at beginning of a line in csh

What does an ampersand at the beginning of a line do in csh? It seems to be ignored (with no error message), but why? Example: & echo 'hi there' performs the expected echo with no error ...
5
votes
1answer
4k views

How do I set 'max threads per process' ulimit for non-root user?

Ulimit man page suggests -r option will set this but it only appears to be valid for the root user and there is no equivalent for setting it via /etc/security/limits? Any ideas?
4
votes
3answers
147 views

Where can I find the source for the unix app 'free'?

Free is a rather hard word to Google for, all my variations failed to bring up anything related to the unix app free (it's for viewing memory usage - free -m etc.). If anyone has a link to the source ...
2
votes
1answer
7k views

What is the rootvg in AIX?

What is the rootvg in AIX? Is it something that is unique to AIX?
0
votes
2answers
86 views

Unix / Linux: backing up an app installation

I was having a discussion recently regarding the fact that *nix doesn't use things like a registry (in the Windows sense) and how this means that everything related to an application (or anything for ...
1
vote
2answers
271 views

Automating a multi-tape cpio backup

Currently, I have a simple backup process in which a script is run daily via cron. If there's a tape in the drive, it will use cpio to backup critical files, with a full system backup done once a ...
2
votes
2answers
1k views

How to change VGA mode after boot and login with ubuntu?

Is there a way to change the screen resolution of the console after the system has been booted? I've seen plenty on setting the vga= line in the boot and in the grub config but I'd like to be able to ...
3
votes
1answer
911 views

cp -R source_dir/* dest_dir/ does overwrite files?

I am trying to copy, recursively, the content of a directory to another using: cp -Rv source_dir/* dest_dir/ It seems that everything work ok but when I list that directory with ls -l the change ...
1
vote
2answers
2k views

What day/time does a weekly cron start on?

I had a look though the cron man but didn't find anything that helped :( Anyone know?
4
votes
4answers
2k views

Block access to a website in Linux

Hey guys, I was trying on blocking some of the websites that I usually use even I need to work hard, e.g facebook. I am using Ubuntu 9.10 and I tried to change the /etc/hosts file by adding ...
5
votes
1answer
914 views

Acessing a mercurial repository on a shared host over SSH

I have a shared hosting account with SSH access. I have set up a virtual Python installation and have copies of the system folders in $HOME: ~/bin, ~/lib ... I have installed mercurial through ...
1
vote
2answers
196 views

Unicode versions of common UNIX text tools to run on Windows

I can't afford the MKS toolkit (also think its a bit overkill for my needs). So I was wondering is anyone knew of the standard set of unix text tools but that can handle unicode files under Windows. ...
1
vote
1answer
1k views

shell / ssh / tty session logger

Good day to you. I know there's some variations of my question here, but they are a bit different I assure you. We use terminal servers that our admins connect to and then establish ssh ...
0
votes
2answers
165 views

diff script command to mail

Is there a way to add a command to mail this if it finds any changes in the /newchanes.list. mail with an attachment(/changes) saying it found changes and if not then the subject line would say: no ...
1
vote
5answers
203 views

Best way to manage $PATH varibles?

I looking for a way to easier manage my $PATH variables. executing $PATH returns me: ...
1
vote
1answer
614 views

Cannot SVN checkout when anon-access = none

When I have anon-access = write Everything works fine. When I change svnserve.conf to: anon-access = none auth-access = write And uncomment password-db and authz-db AND add user in authz with rw ...
1
vote
2answers
681 views

how to recover a .c file in AIX unix which has removed (rm -f) by accidentally

how to recover a .c file in AIX unix which has removed (rm -f) by accidentally
2
votes
4answers
331 views

How to figure out what Linux/Unix distro you are on

Is there a way to tell which Linux flavor and version on the machine I am on running? This may be a strange question, but if I'm given a machine and connect to the monitor and the keyboard and if the ...
1
vote
1answer
537 views

number of characters per line printed by lpr

How do I set the number of characters per line when printing a file using lp or lpr? It seems like it's fixed at 80.
3
votes
1answer
585 views

Can i call pushd/popd and prevent it printing the stack?

After calling pushd/popd in bash, it will print off the current directory stack. Is there any way to prevent this behaviour, so that it will act 'quitely'? This sort of noise in a command is uncommon ...
12
votes
6answers
7k views

Git - post-receive hook with git pull “Failed to find a valid git directory”

It's very weird but when setting a git repository and creating a post-receive hook with: echo "--initializing hook--" cd ~/websites/testing echo "--prepare update--" git pull echo "--update ...
1
vote
2answers
321 views

Is it a good idea to chmod my Python site-packages directory to 777?

I use Python on Linux and OS X, and I'm trying to think of a good reason not to chmod my Python site-packages directory to 777. It seems like that is better to do than sudoing every time I want to ...
5
votes
2answers
9k views

UNIX - How to give user rights over another user and so I don't need to sudo or type password?

I have 2 users in question • git user - used for gitosis - so it's a No password user and it can be accessed only through root... • user user - where my files reside so what I would like to do is ...
1
vote
4answers
991 views

Create file with variable value in Unix

How can I create a file in unix or linux based on variable value ? Ex: If I store date in a variable in linux, YESTERDAY=`date --date='1 day ago' '+%d-%m-%Y'` it will store value to YESTERDAY as ...
3
votes
1answer
543 views

snmpwalk: Supressing the “Wrong Type (should be xxx)” when loading a custom mib

I'm using some custom mibs but for some items I get a message like: $ snmpwalk -c enterprise -v 1 -M mib -m ALL host iso.3.6.1.4.1.5485.2.10.111.1.1 ... MYCOMPANY-MIB::rejectedMessages.11 = Wrong ...
0
votes
1answer
323 views

Determine group of unreadable unix/linux directory

dcoles1@shovel:/ $ cd /DriveXT dcoles1@shovel:/DriveXT $ ls . unreadable dcoles1@shovel:/DriveXT $ cd /DriveXT/MML/ dcoles1@shovel:/DriveXT/MML $ ls . unreadable dcoles1@shovel:/DriveXT/MML $ ...
1
vote
4answers
1k views

Make ls print it all on one line (like in terminal)

ls prints differently depending on whether the output is to a terminal or to something else. e.g.: $ ls . file1 file2 $ ls . | head file1 file2 Is there some way to make ls print out on one line ...
16
votes
6answers
5k views

Bash Loop - How to stop the loop when I press Control-C inside a command?

I am rsyncing a few directories. I have a bash terminal open and am executing something like this: for DIR in * ; do rsync -a $DIR example.com:somewhere/ ; done However if I want to stop the whole ...
7
votes
4answers
3k views

How big (in bits) is a Unix UID?

I understand that unix user IDs (UIDs) are usually 16 or 32 bit unsigned integers but how can I find out for any given system (in a shell)?
12
votes
1answer
7k views

rsync - Exclude files that are over a certain size?

I am doing a backup of my desktop to a remote machine. I'm basically doing rsync -a ~ example.com:backup/ However there are loads of large files, e.g. wikipedia dumps etc. Most of the files I care a ...
2
votes
6answers
375 views

Last command issued on a GNU/Linux box

Someone asked at the mailing list of my local LUG if there is any way of learning the last command issued on a GNU/Linux system. We're talking last command in a system-wide fashion I guess. After ...
0
votes
1answer
818 views

Why can't I successfully install mysql server?

It's very easy. All I want to do is this: aptitude remove mysql-server mysql-server-5.0 --purge aptitude install mysql-server But when I try to run that I get this error: root@db2:/etc# aptitude ...
2
votes
2answers
587 views

A more useful MySQL Query log that's suitable for tail -f'ing

In order to debug a webapp and mysql queries, I've enabled the mysql query log. However it's not a very good format to tail and grep through. Ideally I'd like to be able to only show queries from a ...
4
votes
3answers
1k views

xargs --max-proc split output per proc?

I recently discovered the xargs --max-procs feature. How can split the output of the command by proc? Should I just create a mycommand --logfile $LOGFILE, or can I do it from xargs itself? An ...
0
votes
1answer
224 views

Does smbfs create constant inode numbers?

If I use smbfs to mount a filesystem, will the inodes always be the same for each file? Or am I in danger of the inodes changing when I mount the fs again or if the remote system reboots?
0
votes
1answer
407 views

How to “distribute” memcached?

I know how to install and use memcached on one server. But I heard you can "distribute it"? How does that work, and how can I enable that feature?
5
votes
2answers
332 views

Please explain the following o/p of “top” command

Please explain the following line from the "top" command in the bold :- Mem: 1026228k total, 449640k used, 576588k free, 44812k buffers Swap: 1052248k total, 2020k used, 1050228k ...
4
votes
6answers
450 views

Is it a good idea to encrypt files in unix?

There are (pdf) files placed under unix with 700 permission. The files contain sensitive data. Would it be a good idea to also encrypt these files? Would it make them any more secure?
2
votes
2answers
663 views

make noise on redhat when command is finished

i am developing some software with a significant build time, so i want to execute the build command and play a noise once it is finished. two questions: how do i make some noise from the command ...
0
votes
1answer
992 views

Get all files using FTP via Unix Terminal

Using the FTP command in the Unix terminal I want to download all files / folders from my FTP server. When I use this command: ftp> mget * I get lots of these errors: ftp: Unable to determine ...
3
votes
5answers
220 views

How do I keep track of all IPs that logs into my UNIX computer?

I am using Ubuntu. Is there a good system that can do this?
8
votes
2answers
2k views

unix user alias

is there a way to set up user aliases in unix such that if you have a user, my_user, they can log in with an alternate username, i.e. my_user_alternate and still be logged in as my_user?
1
vote
2answers
195 views

Selective syncronisation of two directories in UNIX (Solaris)

I'm wondering if anyone knows of a nice way to partially duplicate (hard link) files between two directory structures? My current fall back is a script invoked by cron. As background: I ask since I ...
1
vote
2answers
704 views

CRON job erratic behavior with Bourne shell script

I have the following script, that runs normally when I type the script name at the prompt (logscript): #!/bin/sh dvar=`date +"%m\/%d\/%y"` filedate=`date +%b%d%Y` echo DSS1 > ...
0
votes
2answers
549 views

Bash & blocking processes

Could you help me with the Bash syntax to achieve the following? Run a blocking process without blocking execution of the rest of the script. Run a standard "non-blocking" process (e.g. lsof). ...
1
vote
2answers
3k views

Updating a file in a zip archive from STDIN

I want to update/freshen a file in a zip archive with the contents of stdin. So far I haven't been able to find a way to tell the zip command that the contents of stdin correspond to a particular ...
0
votes
2answers
2k views

SSH not redirecting stdout to local terminal

I have the following relevant lines in a csh script: #!/bin/csh -xv set dvar = `date +"^%m\/%d\/%y"` set filedate = `date +%b%d%Y` set grepstring = "grep "\"$dvar\"" </home/user/log/logfile" set ...