LxCenter HyperVM & Kloxo Support

Forum



Members   Search      Help    Register    Login    Home
Home » LxCenter » Command-line Management » Higher understanding of reflect(What the heck are the reflected parameters?)
Higher understanding of reflect [message #79657] Fri, 11 February 2011 17:56 Go to next message
semir is currently offline semir  Hungary
Messages: 976
Registered: January 2011
Location: Hungary
Senior Master
Forum Moderator
LxCenter Evangelist
Edit: actually this is for hypervm, but kloxo is very much the same with other class names and options.

Hi there,

I believe, and correct me if there is some hidden information, that the hardest part to understand in reflect is the response of it. There are 1 or 2 topics explaining it, but I did not got it (mostly because they were all about --class=web).
When to use reflect --type=add, --type=action, --type=property?
Though, some things I still dont understand, here is what I got now:

For eg.:
./reflect --type=update  --class=vps --name=boxname.vm


wont tell you anything. But if you try:
./reflect --type=action  --class=vps


then you'll get back a long list, which most likely starts like this:

update_ostemplatelist Ostemplate List
update_timezone Set Timezone
update_boot Boot
graph_base Graphs
graph_traffic Traffic
[....]
update_limit Limit
[....]

If you take any action, that starts with update_, cut down update, you can use the update script to run that action.
Of course, you'll still have no clues about what to do with it.
Then (if you want to know what you run:

./reflect --type=update  --class=vps --name=debianx.vm --subaction=limit


priv-disk_usage Disk:Disk Quota (MB)
priv-backup_num Backup:Number Of Backups
[...]


You'll get a bunch of modifiable variable names. Then you can use the update script to actually modify a var. For example the disk usage:

./reflect --type=update  --class=vps --name=debianx.vm --subaction=limit --v-priv-disk_usage=2000

Dont forget the --v- tag.

If a reflect --type --subaction type command does not return anyting, there is a possibility that that command does not take arguments (like boot) or you misstyped something.

Of course, you dont have to use the reflect scrit, if you already know the subaction and arguments.

More examples:
Update timezone:
./reflect --type=update  --class=vps --name=debianx.vm --subaction=timezone

timezone Timezone
./update --class=vps --name=debianx.vm --subaction=timezone --v-timezone=Europe/Budapest



Tells you the available limit variables:
./reflect --type=update  --class=resourceplan --name=basic_x___client-admin --subaction=limit


Change resplan flag:
 ./update  --class=resourceplan --name=proba___client-admin --subaction=limit      --v-priv-vps_add_flag=off



I am sure that I havent solved all your problems and this is a rough road, but hopefully I helped Smile

Best wishes,
Semir


ProfiVPS.com Cheap VPS hosting! Buy it from me Smile
ProfiVPS.hu Megbízható, Olcsó VPS bérlés, Virtuális szerver bérlés

If I helped you, please consider putting my link on your site/blog! Thank you in advance Smile

[Updated on: Tue, 21 June 2011 18:40]

Report message to a moderator

Re: Higher understanding of reflect [message #82539 is a reply to message #79657] Mon, 25 April 2011 14:56 Go to previous message
showstep is currently offline showstep  Thailand
Messages: 2
Registered: April 2011
Member
I Like ^^"
Previous Topic:HyperVM add VPS
Next Topic:Scripting help
Goto Forum:
  


Current Time: Fri May 24 17:41:25 EDT 2013

Total time taken to generate the page: 0.01138 seconds
.:: Contact :: Home :: Privacy ::.

Click here to lend your support to: LxCenter and make a donation at www.pledgie.com !

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software