LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-24-2012, 02:37 AM   #1
danibhai
Member
 
Registered: Oct 2009
Posts: 35
Blog Entries: 2

Rep: Reputation: 0
Question Need an Application that consumes 80% of RAM usage..


Hi ,

I Need any linux application that i need to run on my fedora 16 , that would consume min 80 % of memory usage during its execution, considering i'm running on 2 cpu, 2gb ram on a fedora 16 virtual machine.

Please do suggest..!!
 
Old 09-24-2012, 02:39 AM   #2
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 9,373

Rep: Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753
you can write such app in c in an hour. Just use malloc...
 
2 members found this post helpful.
Old 09-24-2012, 02:46 AM   #3
danibhai
Member
 
Registered: Oct 2009
Posts: 35
Blog Entries: 2

Original Poster
Rep: Reputation: 0
I'm bit weak in scripts n programming, would be great if u can let me know any , be it third party application , say , after installing and running it , it should consume 80% of ram, Thanks..
I just intend to take logs of that application with pid that is causing high mem usage..thats it.
 
Old 09-24-2012, 03:05 PM   #4
jefro
Moderator
 
Registered: Mar 2008
Posts: 16,544

Rep: Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428Reputation: 2428
Use ram disk or ramdrive? Does it have to be an application?
 
Old 09-24-2012, 03:15 PM   #5
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 18,903

Rep: Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262
Quote:
Originally Posted by danibhai View Post
I'm bit weak in scripts n programming, would be great if u can let me know any , be it third party application , say , after installing and running it , it should consume 80% of ram, Thanks..
I just intend to take logs of that application with pid that is causing high mem usage..thats it.
Spell out your words....and you've been registered here for three years. Have you not done/tried ANYTHING after three years of using Linux?? Pan64 gave you a good start...did you not bother trying to even look it up, or do anything with it? Just putting "malloc c program to use all ram" into Google pulls up this as the VERY FIRST HIT:
http://stackoverflow.com/questions/1...exhaust-memory

...with source-code, explanations, and tips.
 
Old 09-26-2012, 01:42 AM   #6
danibhai
Member
 
Registered: Oct 2009
Posts: 35
Blog Entries: 2

Original Poster
Rep: Reputation: 0
Thanks every one, TB0ne ->> I'm specifiably looking for an application just like Jmeter, for stress testing, its my fault i did not clear my query in the beginning.C program does not serve my purpose.. True i have been a member for almost 3 years, and i do tweak with Linux commands and unix concepts, thanks to this forum... for all the help..
 
Old 09-26-2012, 01:46 AM   #7
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 9,373

Rep: Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753
What is the problem with c? It is probably the simplest way (I just read your first post again). You can use awk, perl or whatever language you know, just tell us what do you prefer and what suits your needs
 
Old 09-26-2012, 07:51 AM   #8
linuxxer
Member
 
Registered: Apr 2011
Location: I have my own planet
Distribution: SlackwareŽ
Posts: 90
Blog Entries: 1

Rep: Reputation: Disabled
Quote:
Originally Posted by danibhai View Post
that would consume min 80 % of memory usage during its execution
Code:
NO=
MEMSIZE=

for num in $(seq 1 $NO)
do
dd if=/dev/zero of=/dev/null bs=$MEMSIZE &
done
I think, this will work.
 
Old 09-26-2012, 08:30 AM   #9
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,353
Blog Entries: 55

Rep: Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541
Why re-invent the wheel? There's a simple application that can provide about any kind of load and it's called stress.
 
1 members found this post helpful.
Old 09-26-2012, 09:12 AM   #10
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 18,903

Rep: Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262Reputation: 4262
Quote:
Originally Posted by danibhai View Post
Thanks every one, TB0ne ->> I'm specifiably looking for an application just like Jmeter, for stress testing, its my fault i did not clear my query in the beginning.C program does not serve my purpose.. True i have been a member for almost 3 years, and i do tweak with Linux commands and unix concepts, thanks to this forum... for all the help..
The stress application is a good fit. But danibhai, the question of why a program written in a certain language 'does not serve my purpose' doesn't make sense. You asked for a way to use 80% of RAM...you were given a way to use 80% of RAM, the program was already written in the thread provided. Copy/paste it to a file, compile it, run it.
 
1 members found this post helpful.
Old 09-27-2012, 07:10 AM   #11
linuxxer
Member
 
Registered: Apr 2011
Location: I have my own planet
Distribution: SlackwareŽ
Posts: 90
Blog Entries: 1

Rep: Reputation: Disabled
Quote:
Originally Posted by unSpawn View Post
Why re-invent the wheel? There's a simple application that can provide about any kind of load and it's called stress.
Thanks for this link.
It is really helpful.
 
Old 09-27-2012, 07:55 AM   #12
danibhai
Member
 
Registered: Oct 2009
Posts: 35
Blog Entries: 2

Original Poster
Rep: Reputation: 0
Thank you all for the help.. Appreciate it..
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
"free" shows far more memory usage than summing up application usage kenneho Linux - Server 2 08-06-2010 07:56 AM
slackware consumes less RAM . shankar Linux - Distributions 4 07-24-2009 04:33 AM
RAM usage Deelk Linux - General 11 03-27-2006 03:03 PM
Mystery memory usage - what consumes my RAM? Z038 Linux - General 9 03-20-2006 10:17 PM
RH9 consumes 214MB of Ram? taoweijia Linux - General 4 01-07-2005 01:02 PM


All times are GMT -5. The time now is 02:39 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration