Sponsored Content
Full Discussion: Distribution of load
Top Forums Shell Programming and Scripting Distribution of load Post 302849757 by Scripter19 on Tuesday 3rd of September 2013 07:59:51 AM
Old 09-03-2013
Distribution of load

I have load balancing requirement, where I need to do little arithmetic and get the results.
Code:
Server1 - OverLoad - 252
Server2 - OverLoad - 431
Server3 - AcceptLoad - 550
Server4 - AcceptLoad - 59
Server5 - AcceptLoad - 224
Server6 - OverLoad - 10
.....



Now I have a requirement to balance it. If it is overloaded then i need to know how much other server can accept.

As like, the script to evaluate and tell me
Code:
    Server1's load 252 can be moved to Server3 (all 252 since it has 550 has capacity)
    Server2's load 298 can be moved to Server3 (550- 252 = 298, since 252 is already occupied by server1's load)
    Server2's load 59 can be moved to Server4 (59, Maximum available is 59 only)
    Server2's load 74 can be moved to Server 5 (74 = 431 -298-59, after shared with Server3,4)
    Server6's load 10 can be moved to Server 5 (It has got more space to accommodate)

The number of servers may vary and script has to read all the lines and suggest a balancing limits.

or anyother suggestion to balance it well ? Any idea on this would be helpful
 

5 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

could not load hme

After installing Solaris patches, i faced this problem which the system could not load hme ( network interface). after booting up the system i try to configure the IP add. on hme (ifconfig hme inet ......),but it fails. the /etc/hostname.hme0 file exists & is ok & in Prom mode also after running... (1 Reply)
Discussion started by: nikk
1 Replies

2. UNIX for Dummies Questions & Answers

Load error

hi i am facing a problem when i run a shell script to load a table.the error is Record 1: Rejected - Error on table TRENDS."SHP_CUST_ORD_ITM". ORA-14400: inserted partition key is beyond highest legal partition key Record 2: Rejected - Error on table TRENDS."SHP_CUST_ORD_ITM", column... (4 Replies)
Discussion started by: musavir19
4 Replies

3. UNIX for Dummies Questions & Answers

load Balance

Guys im trying to create a script that will load ballance 3 devices. Unix is still very alien to me having only been in this position for 3 months now. Not to mention the fact that i've been thrown in the deep end. Anyway so far i've managed to make a script that looks at all 4 devices and make a... (1 Reply)
Discussion started by: yorkyboy
1 Replies

4. Shell Programming and Scripting

Need help in wrting Load Script for a Load-Resume type of load.

hi all need your help. I am wrting a script that will load data into the table. then on another load will append the data into the existing table. Regards Ankit (1 Reply)
Discussion started by: ankitgupta
1 Replies

5. UNIX for Dummies Questions & Answers

VPS has load 200, httpd load no activity, netstat nothing

Hello, on my hostserver i see one VPS of mine got load of 200.00 and netstat nothing (not a single blank line on netstat command) after some time, netstat started showing connections, but i see no excessive IP connections. tail -f /var/log/httpd/access_log shows no activity /var/log/messages ;... (1 Reply)
Discussion started by: postcd
1 Replies
SHANTY(1)							      Shanty								 SHANTY(1)

NAME
Shanty - Makes a PostScript file from an image and some text. SYNOPSIS
shanty -i image_file [-t text_file] [-o output_file] [-s paper_size] [-d density] [-m margin] [-b background_color] [-x padding] [-n title] [-l orientation] [-rtl] [-btt] [-f font_name] [-altgd] DESCRIPTION
Shanty takes a text file and an image (PNG or JPG) and creates a PostScript file where one pixel in the image becomes one character in the PostScript. OPTIONS
-i, -image Name of the image to load in. JPG and PNG images are supported. This is the only compulsory field. -t, -text Name of the text file to load in, if omitted STDIN is used. -o, -output Name of the PostScript file to produce, if omitted STDOUT is used. -s, -size Size of the paper to work with. This field should be one of: "a0", "a2", "a3", "a4", "a5", "a6", "letter", "broadsheet", "ledger", "tabloid", "legal", "executive" and "36x36". Default is "a4". -d, -density Density of the text. Higher numbers are more dense, default is 1.4. -m, -margin The margins of the page in cm. Default is 1. -b, -background The colour of a backing rectangle to place behind the text. Colours are specified as "R,G,B" with each value between 0 and 255. "off" means no backing colour. Default is "off". -x, -p, -padding Density of the text. Higher numbers are more dense, default is 1.4. -n, -title The title of the output to write as meta-data in the PostScript file. Default is "Shanty output". -l, -orientation The orientation of the paper, can be "portrait", "landscape" or "auto". Default is "auto". -rtl Switch to right-to-left text. -btt Switch to bottom-to-top text. -f, -font Specify font. The font name specified must be visible to the not just make a font magically appear. Default is "Courier-Bold". -altgd If you have problems loading the GD library, try this switch. HOMEPAGE
<http://www.codebunny.org/coding/shanty/> AUTHOR
Duncan Martin <duncan@codebunny.org> ACKNOWLEDGEMENTS
Many thanks to DFB <http://www.cs.nott.ac.uk/~dfb/> and contributors to comp.lang.postscript. Duncan Martin 6 October 2006 SHANTY(1)
All times are GMT -4. The time now is 06:40 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy