Bitcoin Forum
August 18, 2019, 02:29:59 PM *
News: Latest Bitcoin Core release: 0.18.0 [Torrent] (New!)
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: For mining on ubuntu,how can I limit the CPU load?  (Read 441 times)
supercanada1
Sr. Member
****
Offline Offline

Activity: 658
Merit: 250



View Profile
July 18, 2015, 11:58:30 PM
 #1

Since the VPS limit the usage for the cpu, I have to limit the usage of miner when I setup the miner on ubuntu server, I installed cpulimit but it looks like not easy to use:
cpulimit -P /mycoin/src/myminer -l 25
I try to run this on ubuntu but it looks like it will not run background, any way to let this run on background?
also, I must run myminer first, and then run cpulimit command, is this any way I can just limit my cpu usuage first and then the miner later?
because if I run miner first, it will take lot of the cpu usage immediately

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
Everything that makes you vital
▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

████████████  █████  WHITEPAPER  █████  ████████████
███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
▄▄███████████▄
▄███▀▀▀▀▀▀▀▀▀████
███           ▀███
███            ███
███   ▄█████▄  ███
███  ███▀▀▀████▄▀
███  ██     ▄▀███▄
███  ███▄▄▄███ ▀███▄
███   ▀█████▀    ▀███
███               ███
███              ▄███
▀███▄▄▄▄▄▄▄▄▄▄▄▄████
 ▀▀██████████████▀▀
BitVit███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1566138599
Hero Member
*
Offline Offline

Posts: 1566138599

View Profile Personal Message (Offline)

Ignore
1566138599
Reply with quote  #2

1566138599
Report to moderator
1566138599
Hero Member
*
Offline Offline

Posts: 1566138599

View Profile Personal Message (Offline)

Ignore
1566138599
Reply with quote  #2

1566138599
Report to moderator
supercanada1
Sr. Member
****
Offline Offline

Activity: 658
Merit: 250



View Profile
July 19, 2015, 12:04:05 AM
 #2

or any way just to limit the cpu usage of my whole account

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
Everything that makes you vital
▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

████████████  █████  WHITEPAPER  █████  ████████████
███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
▄▄███████████▄
▄███▀▀▀▀▀▀▀▀▀████
███           ▀███
███            ███
███   ▄█████▄  ███
███  ███▀▀▀████▄▀
███  ██     ▄▀███▄
███  ███▄▄▄███ ▀███▄
███   ▀█████▀    ▀███
███               ███
███              ▄███
▀███▄▄▄▄▄▄▄▄▄▄▄▄████
 ▀▀██████████████▀▀
BitVit███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███

███  ███  ███
TreasureSeeker
Sr. Member
****
Offline Offline

Activity: 457
Merit: 251



View Profile WWW
July 19, 2015, 06:40:13 PM
Merited by d5000 (1)
 #3

Popping an ampersand at the end should let it run in the background.  Give it some niceness too if you're concerned about it slowing down other processes:
Code:
nice -n 19 cpulimit -P /mycoin/src/myminer -l 25 &

Fun & Friendly p2pool Mining at TreasureQuarry.  Litecoin http://litecoin.treasurequarry.com:9327 Dash p2pool  http://dash.treasurequarry.com:7903
mullick
Legendary
*
Offline Offline

Activity: 966
Merit: 1000


View Profile
July 19, 2015, 10:19:43 PM
 #4

If your cpu mining then im going to assume your mining with the daemon of the coin itself. In that case

Code:
proc=x

Where x = the number of cores you want utilized. Adding that line to your config file will do the trick for most codebases
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!