General :: Tar Gz Shell Script Fails / Get It To Work?
Jul 27, 2010
Someone gave me a script that would tar then gzip my music directory, as well as remove the previous days backup. I have it set up in crontab, but it appears to have stopped working the last couple days, so i tried running it manually. Below is the script and the output I got. Any ideas why its failing now? I don't think anything changed on the server, maybe someone installed updates but idk why that would affect this.
Here's the musicbackup.sh script code...
View 3 Replies
ADVERTISEMENT
Nov 20, 2010
I'm attempting to mount a Windows dir to a mount point on my Linux VMWare instance running on my Windows 7 machine. I am using a shell file to automatically mount the directory I want at bootup. However, I'm finding that Linux always mounts to a directory at the top of my C: file structure for some reason, and I can't figure out why.
Here's the dir structure:
C:/target (don't want to mount this, but this is what gets mounted)
C:/Users/me/target (this is what I want to mount to)
Here's my shell script:
Code:
mount.cifs //192.168.56.1/Users/me/target /mnt/target -o credentials=/root/credentials.auth,domain=mycomputer,uid=1001,gid=1001,rw
And here's what I get when I enter mount at the prompt:
Code:
/dev/mapper/VolGroup00-LogVol00 on / type ext3 (rw)
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/sda1 on /boot type ext3 (rw)
none on /dev/shm type tmpfs (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
If this means anything my Virtual Machine has a single hard drive SCSI, which I believe is /dev/sda1. I don't see anything from mount that would indicate that the c:/target dir is getting hard-mounted somehow from the /etc/vfstab file, but maybe I just don't understand how mounting works...
View 2 Replies
View Related
Feb 12, 2011
When I try to launch application which runs in another window (not inside shell), it always fails with this kind of message: (example from gnome-terminal)
Code:
** (gnome-terminal:2477): WARNING **: Failed to connect to the session manager: None of the authentication protocols specified are supported Failed to get the session bus: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Falling back to non-factory mode. Failed to summon the GConf demon; exiting. Failed to contact configuration server; the most common cause is a missing or misconfigured D-Bus session bus daemon. See [URL] for information. (Details - 1: Failed to get connection to session: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.) I am running it as root, have GNOME installed and running, and also fresh install of gconf.
View 8 Replies
View Related
Feb 9, 2010
This is a very simple problem, but I'm scratching my head with others..
In composing a simple shell script in class, we can't seem to get the script to execute fully. script was formatted as follows.
#!/bin/bash
echo "good bye for now"
exit
did, Chmod 755 to make executable
type file name "bye"
runs but wont exit.....
it just echos the type"good bye for now
The instructor says it works for him at home....
But it wont work in class...
Is there a reason it wont "exit" the shell as commanded ?
View 11 Replies
View Related
May 3, 2011
I am having trouble using grep command. I want to search for each line in first file in second file and if they are present, write to file called successfile else to failfile. Below is the code
what is happening is, when the first failure occurs (when a line in first file is not present in second file), the script is killed.
Can anyone please tell me what I am doing wrong? code...
View 4 Replies
View Related
Jun 16, 2011
Why does this work
Code:
for myfile in `find . -name "R*VER" -mtime +1`
do
[code]...
View 2 Replies
View Related
Mar 9, 2010
I tried to create a user on Solaris 10 but when I try to login the user with "su -" I get the error message "no directory". When I try to login with "su" I get the error message "no shell".
I tried the useradd several combinations e.g.
All the tries i made didn't work. I also checked the permissions on /etc, /bin, /sbin and / and it seems ok so that the newly created user can access them.
View 14 Replies
View Related
Jul 9, 2010
I am using a server where i need to login twice. The first time i login as my boxname and pass. The 2nd login is 'root' so i can access the content of the box (i dont understand it but that hasnt stopped me from using it as normal).Now i like a GUI so i can browse files easier and drag and drop multiple files instead of using the command line. WinSCP doesnt work as it locks up. I suspect its because there is a prompt to log in again.
What can i use to drag & drop files?
View 3 Replies
View Related
Jul 11, 2011
I have an Ubuntu server running Couch Potato, Sick Beard and Sabnzbdplus. Everything "works" pretty well in a sense that CP and SB push the NZB's to Sabnzbdplus, but Sab crashes regularly (haven't found the solution or the cause for this problem, so if you have some advice regarding that, it's welcome).To counter this problem (Sab crashing) I have a script written which checks if Sab is runnning and if it isn't start it:
Code:
bart@Pyro:~$ cat CheckSabRunning.sh
#!/bin/sh
[code]....
View 9 Replies
View Related
Dec 27, 2010
From one day to the other my system stopped booting properly. Since I (finally) fixed it, I wanted to share my solution. It runs on a fakeraid pair of SSD's of 60 GB each (actually a single Revodrive device, but it shows up as two devices). When Ubuntu 10.10 boots, I'm dropped to a shell.During boot, when I removed "silent splash" from the kernel's command line, I got these messages:
Code:
[ 4.960240] scsi 6:0:0:0: Direct-Access ATA OCZ-REVODRIVE 1.20 PQ: 0 ANSI: 5
[ 4.960425] sd 6:0:0:0: [sdg] 117231408 512-byte logical blocks: (60.0 GB/55.8 GiB)
[cod]....
I doubt that this is what was needed (as I had that already when it didn't work, but I might be required in addition to installing dmraid)
# update-initramfs -a
After installing this, the problem was solved!! This is strange since I don't recall uninstalling this package or changing anything important, for that matter (perhaps did apt-get upgrade, but that's about it!). [URL]
View 2 Replies
View Related
Jun 30, 2011
I am trying to fix a perl script, and I really suck at perl. But I think this problem will be easy for people who know it.
The problem is, I have an old setup script someone wrote many years ago. It fails if the standard shell is dash and not bash. The only way I've gotten it to work is to point /bin/sh to bash. I looked thru the script and it uses "system" many places, and I think that's the problem.
I searched for it and found this link:url
My plan is to include this function:
Code:
sub system_bash {
my @args = ( "bash", "-c", shift );
system(@args);
}
Then I could simply change all calls to system into system_bash and it should work?
The parameter to the system calls is usually some variable. What if the parameter is a list already? Do I need to test for it somehow, and if it's a list, prepend "bash" and "-c" to the list? How do I do that?
In the script there are lots of places like this:
my $error = system($cmd);
if ($error) {
die/warn "some error message";
}
Shouldn't there be a return in the system_bash function?
View 8 Replies
View Related
Feb 16, 2011
I am running a Java application on the command line bash terminal under Mint Debian. I have JDK1.6.0_22 installed 64-bit, and the OS is 64-bit too. I have a few JAR files in the directory and a few native LWJGL libraries. When I run the application using the command line, all works fine.
Lets assume my directory where the files are is called /home/riz/MyGame. I change to that directory and this is the command I use code...
View 3 Replies
View Related
Jun 15, 2011
MACHINE: HP Proliant DL260G5OS: SLES 11 SP1kernel: Linux xserver 2.6.32.12-0.7-default #1 SMP 2010-05-20 11:14:20 +0200 x86_64 x86_64 x86_64 GNU/LinuxIt is used as remote xserver in a LAN.I have configured /usr/lib/restricted/bin/.rbashrc with some environment variables but when the users logon in the system finally is executed $HOME/.bashrc and some environment vars are overwritten.
View 2 Replies
View Related
Apr 27, 2011
I would like know when it is necessary or advisable to write a shell script instead of shell function ?
View 3 Replies
View Related
Jan 18, 2011
I am wondering if I can open a shell or new terminal thing from within the terminal in a unix/linux enviroment. Particularly a commandline only one where there is no GUI. Is this doable? how do I do it?
View 3 Replies
View Related
May 3, 2010
I was upgrading our lab's dhcp server to Lucid and it totally died. I have it running on a Debian recovery cd right now. I ran into a bug in gtk which I seem to have fixed, but now I have more serious errors. If I boot without a CD, I get dumped into a busybox shell after the machine fails to boot. From the live CD, I tried dist-upgrading again and it dies trying to build and install rsyslog with a broken pipe error. I am at a loss as to what to do from here short of reinstalling (which is the last option as this server has a lot of custom configs on it)
View 6 Replies
View Related
May 6, 2011
I've installed KDE 4.6.2 (from Index of /repositories/KDE:/Release:/46/openSUSE_11.4) and I've noticed that Strigi fails to work. In my System Settings I have?message that Strigi haven't started, although it should (the checkbox to strart Srtigi is active). The process virtuoso-t is constantly suspended in the system.
OS: OpenSuse 11.4 64 bit. Some bugs are resolved in KDE 4.6.2 compared to 4.6.00, so I would like to stay with KDE 4.6.2.
View 1 Replies
View Related
May 30, 2010
i tried gnome shell from the software center, but it has some graphics issues. Is it my graphics driver?
View 6 Replies
View Related
May 11, 2011
I have updated GNOME 3 and it no longer works. Having suspected extensions the problem I have manually uninstalled all extensions via command line. This got me to log in instead of the problem screen. However, the desktop is entirely unresponsive, after log in it no longer responds to anything, although the mouse still tracks.
View 9 Replies
View Related
Nov 28, 2009
Cannot find input plugin for MRL [dvd:/] Is now the message that I get when attempting to play DVDs in Kaffeine, which worked very well in SuSe 10,3 three hours ago. Ironically, VLC now works a treat, when upgrading that in 10.3 killed it.Xine doesn't want to work (restricted format), and Kaffeine isn't playing any files either. Has something been dropped from my previous setup, or do I have an inadequate installation? I'm not very command line oriented I'm afraid;I just expect things to work as they did before...:-)
View 4 Replies
View Related
May 9, 2010
I have one laptop running on ubuntu and one computer running on ubuntu.....once i removed ubuntu from my laptop....and installed windows on my laptop but it didn't work as it should work. It used to crash too often. Then i removed windows and put ubuntu on my laptop.. but now i want to put a new hard disk in my computer....but now i want to run both windows and ubuntu.....i just want to ask that does ubuntu leave any strains on my hard disk when i remove it.....and is that the reason windows doesn't work properly
View 6 Replies
View Related
Oct 11, 2010
I'm having a problem getting the website [URL]... to display and function properly on 10.10. What I thought odd was that it fails to work in both Firefox and Chromium, although other Flash applications work fine. Is anyone having the same problem I am? Does anybody know what the issue might be?
View 2 Replies
View Related
Oct 1, 2010
I try to shutdown a box running Fedora (fc12, all updates applied) remotely. From various threats I selected the following way that suits best to my needs: I edited the entry for shutdown in /etc/passwd:
shutdown:x:6:0:shutdown:/sbin:/usr/bin/sudo /sbin/shutdown -h +1
Logging in from a tty with shutdown gives the desired result: The computer does the shutdown. Then I tried the same using sshd and plink:
plink -t -l shutdown -pw xxx 10.0.0.123
As a result I get:
Using username "shutdown".
Access denied
Access denied
shutdown@10.0.0.123's password:
The /var/log/secure shows the following entry:
Oct 2 00:40:46 rotgschirr sshd[6841]: User shutdown not allowed because shell /usr/bin/sudo /sbin/shutdown -h +1 does not exist
Oct 2 00:40:46 rotgschirr sshd[6846]: input_userauth_request: invalid user shutdown
Oct 2 00:40:46 rotgschirr unix_chkpwd[6847]: password check failed for user (shutdown)
Oct 2 00:40:46 rotgschirr sshd[6841]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=rotgschirr.totes-gebirge user=shutdown
Oct 2 00:40:48 rotgschirr sshd[6841]: Failed password for invalid user shutdown from 10.0.0.123 port 37195 ssh2
Oct 2 00:40:50 rotgschirr sshd[6846]: Connection closed by 10.0.0.123
Somehow when using ssh the shell /usr/bin/sudo /sbin/shutdown -h +1 cannot be found.
View 5 Replies
View Related
Nov 23, 2010
What would happen if I place more than one shell script in the cron.weekly directory. would they run at the same time?
View 1 Replies
View Related
Nov 30, 2010
When I add a new user and SSH to my server as that new user, my command prompt is just a '$'. Tab completion doesn't work either. What I notice is that I get this:
Could not chdir to home directory /home/scaldwell: No such file or directory
$
Echo PS1 yields nothing. There is also nothing in /etc/skel. I didn't have to do anything special to get my initial user setup with the right prompt, and the second user has been added to the admin group as well. I have noticed that if I issue the command sudo chsh -s /bin/bash the account gets the correct prompt.
View 1 Replies
View Related
May 14, 2011
I'm trying out gnome-shell right now and for some reason, when I use the alt-tab shortcut, it switches to the next window and then the menu immediately disappears, so I have no ability to look at the detailed menu option. This might have something to do with me having changed a lot of my keyboard shortcuts in regular gnome. For example, I use super-tab rather than mod4-tab. Also, my key to call up the shell is caps lock because my other two super keys (super and right control) are all assigned to various keyboard shortcuts.
View 2 Replies
View Related
Jun 9, 2011
When I type nautilus in shell and run, the nautilus doesn't start.
while I use Alt-F2 and then type nautilus, the nautilus start.
why?
View 4 Replies
View Related
Feb 4, 2010
I am trying to use VirtualBox which worked just a week ago (I haven't changed anything with it) but now it fails. When I try to start it (from the command line) with /usr/bin/VirtualBox, as a regular user, it fails.
View 6 Replies
View Related
May 17, 2010
I installed Ubuntu 10.04 LTS to dual boot with Win Xp and everything went fine with the installation untill I went to boot back into Windows. My keyboard fails to respond in the boot loader so I am stuck with the default setting of booting back into Linux. To be clear, the keyboard works when the BIOS loads, I can hit DEL and go to the BIOS menu, etc, it's only when I hit the boot loader. The keyboard also works fine in Linux and Windows.
View 2 Replies
View Related
Aug 1, 2010
I just did a fresh install of 32bit Ubuntu 10.04 on my desktop and am trying to get some F@H clients working.I installed Origami and did a
Code:
sudo origami install -t blah -u blah -b big
and got the error "STARTUP SCRIPT FAILED TO START!"
[code]....
View 4 Replies
View Related