General :: Bash - How To Close My Script When Done
Jun 25, 2010
I'm working on a script to manage some stuff on my server and I'm trying to figure out how I can close my script when I'm done with it. I open it using &, but how can I kill it with another script? I'm trying to do this programmatically but I'm very unfamiliar with Linux.
View 2 Replies
ADVERTISEMENT
Apr 28, 2011
I've noticed something, and hoped there was a work around.when I write a simple bash script, and run it, if I close the terminal i ran the bash script inside, the bash script stops. What are the solutions for this? Basically I want to run my bash script and close the terminal, keep the bash script running.
View 6 Replies
View Related
Feb 3, 2011
I am trying to get bash script using zentity to exit if the user presses the cancel or close buttons.The exit codes are working fine; they read 1 or 0 depending on the status but it always assumes 0. This is the portion of the script: PHP Code:
function settings(){
result=$(zenity --height=30 --width=300 --list --checklist --title='Selection'--column=Boxes --column=Selections --column="Options"
[code]...
View 2 Replies
View Related
Jan 1, 2010
I have got a bash script i have been playing with I need to start a process then close terminal with in the script but leave program running ?
Code:
#!/bin/bash
sudo ifconfig eth0 down
sleep 5
sudo ifconfig eth0 up
firefox & exit
View 9 Replies
View Related
Nov 29, 2010
I create a bash script that writes another bash file. But in the generated bash file I want to write a bash command in the file and not executing it.Here's my bash file:
Code:
#!/bin/bash
cat > ~/generateGridmix2data.sh << END
[code]...
View 6 Replies
View Related
Jul 17, 2010
below are the details of my system. I have bash as my current shell, some really common commands aren't working.
Do I need to do a re-installation of bash? Or how do I install a selection of bash commands which I need? (for example a subset of [URL])
Code:
root@sdptfw:~ # uname -a
Linux sdptfw.sdpt.co.za 2.4.36 #1 Tue Jul 22 13:13:24 GMT 2008 i686 i686 i386 GNU/Linux
root@sdptfw:~ # echo $SHELL$
/bin/bash$
[Code]....
View 13 Replies
View Related
Jul 13, 2011
The buttons to minimize and close, in the upper right-hand corner, have disappeared, making it impossible to close my browser and shut down my computer.I don't know what to do.
View 9 Replies
View Related
Jun 14, 2011
i know the command to start the x server is "startx" and ctrl alt delete is the keyboard short cut or atleast on slackware, to close X. i wanted to know what the comand is though.
View 5 Replies
View Related
Mar 23, 2010
I tried to close the browser windows; but everything seems freezed. how to close this application from terminal?
View 2 Replies
View Related
Mar 15, 2010
I opened a previous thread in this forum about possible partitioning schemes and don't know how to close it.
View 1 Replies
View Related
Sep 3, 2010
I just started using Fedora Linux Console. I know how to open multiple consoles, but i don't know how to close them.
View 5 Replies
View Related
Oct 27, 2010
play on linux is the only program sorry what it is doing is when i go to install a game and click apply it just stops then when i go to close the program down it says its not responding and wants me to either wait or force quit?
View 2 Replies
View Related
Jan 4, 2011
I have something like:cd project && python manage.py runserver &cd utilities && ./coffee_auto_compiler.pyAnd I want both of them to close on Ctrl-C (or some other command). How can I accomplish that?EDIT:I tried using jobs -x kill and kill `jobs -p `, but it doesn't seem to kill what I need. Here is what I mean:oon 8119 0.0 0.0 7556 3008 pts/0 S 13:17 0:00 /bin/bashmoon 8120 6.8 0.4 24568 18928 pts/0 S 13:17 0:00 python manage.py runserverjobs -p give me just process 8119, but I also need to close 8120, since it's the thing that the first command opened.If it helps, the commands are actually in a Makefile, and I want it to run two daemons at the same time (and somehow close them at the same time).
View 3 Replies
View Related
Jan 9, 2011
I'd like to make the ls -laR /media/myfs on Linux as fast as possible. I'll have 1 million files on the filesystem, 2TB of total file size, and some directories containing as much as 10000 files. Which filesystem should I use and how should I configure it?As far as I understand, the reason why ls -laR is slow because it has to stat(2) each inode (i.e. 1 million stat(2)s), and since inodes are distributed randomly on the disk, each stat(2) needs one disk seek.Here are some solutions I had in mind, none of which I am satisfied with:Create the filesystem on an SSD, because the seek operations on SSDs are fast. This wouldn't work, because a 2TB SSD doesn't exist, or it's prohibitively expensive.
Create a filesystem which spans on two block devices: an SSD and a disk; the disk contains file data, and the SSD contains all the metadata (including directory entries, inodes and POSIX extended attributes). Is there a filesystem which supports this? Would it survive a system crash (power outage)?Use find /media/myfs on ext2, ext3 or ext4, instead of ls -laR /media/myfs, because the former can the advantage of the d_type field (see in the getdents(2) man page), so it doesn't have to stat. Unfortunately, this doesn't meet my requirements, because I need all file sizes as well, which find /media/myfs doesn't print.Use a filesystem, such as VFAT, which stores inodes in the directory entries. I'd love this one, but VFAT is not reliable and flexible enough for me, and I don't know of any other filesystem which does that. Do you? Of course, storing inodes in the directory entries wouldn't work for files with a link count more than 1, but that's not a problem since I have only a few dozen such files in my use case.
Adjust some settings in /proc or sysctl so that inodes are locked to system memory forever. This would not speed up the first ls -laR /media/myfs, but it would make all subsequent invocations amazingly fast. How can I do this? I don't like this idea, because it doesn't speed up the first invocation, which currently takes 30 minutes. Also I'd like to lock the POSIX extended attributes in memory as well. What do I have to do for that?Use a filesystem which has an online defragmentation tool, which can be instructed to relocate inodes to the the beginning of the block device. Once the relocation is done, I can run dd if=/dev/sdb of=/dev/null bs=1M count=256 to get the beginning of the block device fetched to the kernel in-memory cache without seeking, and then the stat(2) operations would be fast, because they read from the cache. Is there a way to lock those inodes and/or blocks into memory once they have been read? Which filesystem has such a defragmentation tool?
View 2 Replies
View Related
May 30, 2010
I installed LM9 and it seems like my close maximize minimize disappeared
View 3 Replies
View Related
Feb 28, 2010
The drop down menu will not close automatically when move mouse outside the menu block ,it just disappear when you click outside the menui use gnome desktop
View 1 Replies
View Related
Jul 7, 2010
I know that ports are, by default, not filtered; they simply don't respond to requests if there are no services listening on the port. Well, running netstat -tulpn gives:
Code:
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN -
[code]....
View 3 Replies
View Related
Mar 18, 2010
I am using ubuntu 9.10 and when i close the lid of the laptop it does not hibernate or suspend?
what do i do?
View 1 Replies
View Related
Jul 19, 2011
In system monitor, there are numerous processes. Some such as metacity and nautilus are using 12-21 mb memory. Since my server is a 512 mb computer, which services or processes can I safely remove or end ?
View 14 Replies
View Related
Sep 14, 2010
How can I force all currently open sockets in linux to close from the command line?
View 2 Replies
View Related
Aug 23, 2011
I'm running Ubuntu 10.4 and I've tried disabling IPv6 as I don't currently need it. I rand the following to disable IPv6 and then rebooted my server:
echo "#disable ipv6" | sudo tee -a /etc/sysctl.conf
echo "net.ipv6.conf.all.disable_ipv6 = 1" | sudo tee -a /etc/sysctl.conf
echo "net.ipv6.conf.default.disable_ipv6 = 1" | sudo tee -a /etc/sysctl.conf
echo "net.ipv6.conf.lo.disable_ipv6 = 1" | sudo tee -a /etc/sysctl.conf
After the reboot I can see that IPv& is disabled by running:
cat /proc/sys/net/ipv6/conf/all/disable_ipv6
On running netstat -antlp i see that most of the IPv6 applications have closed but SSHd keeps running:
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:9090 0.0.0.0:* LISTEN 663/java
[Code]....
Ho can I close the SSH daemon on port 22 of the IPv6?
View 2 Replies
View Related
Aug 19, 2010
On close down of kde4 I get the following error message;'Waiting for X server to shutdown kde4: fatal IO error; client killed error setting MTRR (base=0xf0000000, size=0x04000000, type=1) invalid argument (22)Because of this error I am currently closing down using "shutdown -h(-r) now"Could I please have some help on correcting the error.I have only a meagre experience with linux having only dabbled with it over the years
View 1 Replies
View Related
Mar 29, 2010
how to close or disable ruser and rlogin rhost in linux
so that nobody can connect using above commands
View 5 Replies
View Related
Aug 13, 2010
I am trying to use Rythmbox to replace windows media player, in Ubuntu 10.04. So of course, I needed to import all my music. So in Rythmbox I go to Music>Import Folder and then I simply select the correct folder, which is on a different drive. And sometimes, that works. even though it won't remember that I did it once I close Rythmbox. Other times, when I do that, Rythmbox simply closes right then and there, and has to be reopened. I don't really know what is going on here, other than what I would call a bug. But it never actually keeps the music file that I imported. I always have to re-import it, every time I open Rythmbox.
View 2 Replies
View Related
Jul 7, 2011
I am using Fedora 13 64bit. My eclipse program starts a server on port 9050 but I shutdown the program, eclipse fails to properly shutdown the server. Restarting eclipse has no effect.
How can I close or unbind a port forcibly from command line?
I know rebooting or log off and back on will clear the ports but this much slower process for me. I am looking for forcibly closing the port in command line.
View 1 Replies
View Related
Mar 4, 2010
So... I run df -h and I get this:
Filesystem Size Used Avail Use% Mounted on
/dev/root 293G 21G 258G 8% /
tmpfs 503M 0 503M 0% /dev/shm
/dev/hdd1 113G 12G 96G 11% /win1
/dev/hdc1 113G 109G 0 100% /win0
It's close to full, but not actually full. I can't run a lot of things on this drive because the programs complain that they have no space.
View 3 Replies
View Related
May 17, 2010
How to switch the close,maximize,minimize to right side the window in Ubuntu10.04. I found a way in www.makeuseof.com but that does not work.Run Applic.->gconf-editor->apps/metacity/general->menu:maximize,minimize,close.
View 2 Replies
View Related
Sep 24, 2009
I m using Ubuntu 9.04.I m facing a strange problem.Any of application's window dosen't show close,resize buttons on top right corner of window.I m facing this problem sience i've installed compiz fusion.
View 1 Replies
View Related
Oct 23, 2010
Windows close and minimize buttons have disappeared in Genome. In other desktops like KDE and cfxe they are present BUT I am using Gnome.My distro is Ubuntu ultimate 2.7 64bit.
View 1 Replies
View Related
Jan 17, 2011
i am working on a project that uses message queues. i am able to successfully create them and they are working fine. now the problem is to close/remove message queues without software or mq_close / mq_unlink command. earlier when i worked on rh9, there is ipcs utility. we use ipcs to see all the existing message queues and ipcrm to remove them. however ipcs is not working for message queues in RHEL 5.3. Neither ipcs shows the exisiting message queues and neither we are able to use ipcrm. Plz guide to close/remove the queues with ipcs or any other command/utility from shell itself.
View 1 Replies
View Related