Sponsored Content
Top Forums Shell Programming and Scripting How to clean memory after command run? Post 302894980 by postcd on Friday 28th of March 2014 07:36:51 AM
Old 03-28-2014
How to clean memory after command run?

Hello, i have an loop (while) in bash and i seen after a while sctipt returned like:

Code:
wget: error while loading shared libraries: libselinux.so.1: failed to map segment from shared object: Cannot allocate memory
wget: error while loading shared libraries: libcrypto.so.6: failed to map segment from shared object: Cannot allocate memory
./wgetter: fork: Cannot allocate memory

So i want to ask which command i need to use to reclaim memory used by some command in loop, it appears like this loop causes memory to fill?

so far i found:
clean up memory on linux | commandlinefu.com
https://gist.github.com/pklaus/837023

but not sure if any of these are good to use, the second one is a big script, probably not handy for a loop..

Last edited by postcd; 03-28-2014 at 07:37 PM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to run multiple command in single command?

Dear Unix Guru, I have several directories as below /home/user/ dir1 dir2 dir3 Each directory has different size. I want to print each directory size (Solaris command du -hs .) Can you please guide me how to achieve this? Thanks Bala (2 Replies)
Discussion started by: baluchen
2 Replies

2. Shell Programming and Scripting

Sed command to clean xml tag

Hi, Can someone help me come up with a generic sed command to clean a tag off its attributes? For eg. Input String - <tag attrib=new>This String</tag> should undergo a sed transformation to get Output String - <tag >This String</tag> This works - echo "<tag attrib=new>This</tag>" |... (3 Replies)
Discussion started by: iamwha1am
3 Replies

3. UNIX for Dummies Questions & Answers

command to clean up file systems

As you will verify, I am a really naive user of AIX 5.1. As such I wonder if you could possibly let me know of a command or procedure I could use to automatically, globally and safely, remove all useless files from my machine. I'm not referring to my own files because I perfectly know which of them... (1 Reply)
Discussion started by: ahjchr
1 Replies

4. Programming

How to deal with lots of data in memory in order not to run out of memory

Hi, I'm trying to learn how to manage memory when I have to deal with lots of data. Basically I'm indexing a huge file (5GB, but it can be bigger), by creating tables that holds offset <-> startOfSomeData information. Currently I'm mapping the whole file at once (yep!) but of course the... (1 Reply)
Discussion started by: emitrax
1 Replies

5. Shell Programming and Scripting

Command to find the Memory and CPU utilization using 'top' command

Hi all, I found like top command could be used to find the Memory and CPU utilization. But i want to know how to find the Memory and CPU utilization for a particular user using top command. Thanks in advance. Thanks, Ananthi.U (2 Replies)
Discussion started by: ananthi_ku
2 Replies

6. Shell Programming and Scripting

Is command line invocation of gnome-terminal to run more than one command possible?

Hello, I am trying to learn how to pass something more than a one-command startup for gnome-terminal. I will give an example of what I'm trying to do here: #! /bin/bash # #TODO write this for gnome and xterm USAGE=" ______________________________________________ ${0##*/} run... (0 Replies)
Discussion started by: Narnie
0 Replies

7. Shell Programming and Scripting

Need help! command working ok when executed in command line, but fails when run inside a script!

Hi everyone, when executing this command in unix: echo "WM7 Fatal Alerts:", $(cat query1.txt) > a.csvIt works fine, but running this command in a shell script gives an error saying that there's a syntax error. here is content of my script: tdbsrvr$ vi hc.sh "hc.sh" 22 lines, 509... (4 Replies)
Discussion started by: 4dirk1
4 Replies

8. Shell Programming and Scripting

"Cannot allocate memory" error when run from script

hi in my application there is a line with open(/dev/mydevice,0); it work good when it run manually, but when try to run it within script /////////////////////////////////////////// #!/bin/sh ./device_test 0 0 0 1 1 1 0 0 1 ///////////////////////////////////////// I receive 'Failed... (3 Replies)
Discussion started by: majeed
3 Replies

9. Shell Programming and Scripting

Script for telnet and run one command kill it and run another command using while loop

( sleep 3 echo ${LOGIN} sleep 2 echo ${PSWD} sleep 2 while read line do echo "$line" PID=$? sleep 2 kill -9 $PID done < temp sleep 5 echo "exit" ) | telnet ${HOST} while is executing only command and exits. (5 Replies)
Discussion started by: sooda
5 Replies

10. AIX

How to use dsadm command to run command on multi lpars?

how to run a command, such as "ls -l core" from one lpar to check multi lpars if core file exist? or what way can do a command on all lpars from one lpar? Thanks (1 Reply)
Discussion started by: rainbow_bean
1 Replies
URL(4)							   BSD Kernel Interfaces Manual 						    URL(4)

NAME
url -- Realtek RTL8150L USB Ethernet driver SYNOPSIS
url* at uhub? urlphy* at mii? DESCRIPTION
The url driver provides support for USB Ethernet adapters based on the Realtek RTL8150L USB-ether bridge chip. The url driver supports the following adapters: CompUSA USBKR100 GreenHouse GH-USB100B Melco Inc. LUA-KTX Sitecom LN013 For more information on configuring this device, see ifconfig(8). DIAGNOSTICS
url%d: watchdog timeout A packet was queued for transmission and a transmit command was issued, however the device failed to acknowledge the transmission before a timeout expired. url%d: no memory for rx list The driver failed to allocate an mbuf for the receiver ring. SEE ALSO
arp(4), mii(4), netintro(4), usb(4), ifconfig(8) HISTORY
The url device driver first appeared in NetBSD 1.6. AUTHORS
The url driver was written by Shingo WATANABE <nabe@nabechan.org>. BSD
September 18, 2006 BSD
All times are GMT -4. The time now is 07:17 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy