Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Server Info in Admin Control Panel Details »»
Server Info in Admin Control Panel
Version: 1.0, by Dream Dream is offline
Developer Last Online: Sep 2010 Show Printable Version Email this Page

Category: Administrative and Maintenance Tools - Version: 3.6.8 Rating:
Released: 11-06-2006 Last Update: 03-25-2007 Installs: 173
Re-useable Code Additional Files  
No support by the author.

This is a script that shows a lot of server information inside the AdminCP.

- Shows server time with exec(date)
- Shows uptime with exec(uptime)
- Shows server load with file_get_contents("/proc/loadavg")
- Shows memory usage with exec(free -m)
- Shows free disk space with exec(df -h)
- phpinfo() link
- Shows MySQL Stats with mysql_stat()
- Shows MySQL Status with "SHOW STATUS" query
- Shows MySQL Vars with "SHOW VARIABLES" query

Its superadmin only.

Installation
- Upload "server_info.php" to your admincp
- Upload "cpnav_serverinfo.xml" to your includes/xml
- Reload your AdminCP, its under "Server Info"


Info on Server Loads

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #62  
Old 04-21-2007, 07:10 PM
Dotara's Avatar
Dotara Dotara is offline
 
Join Date: Apr 2007
Location: 127.0.0.1
Posts: 59
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dream View Post
I think you ate a } after

PHP Code:
if ($_REQUEST['show'] == 'memoryusage' || empty($_REQUEST['show'])) {
    
print_form_header('''');
    
print_table_header('Memory Usage &nbsp;<span class="normal">exec(free)</span>');
    
exec('vmstat'$mem);
    
print_description_row('<pre>'.implode('<br />'$mem).'</pre>');
    
print_table_footer(); 
No! I made the mistake in "free" on line 4 where I should put vmstat. I only placed vmstat once instead of twice. Sorry. Now it's working fine

I clicked "Mark as Installed"
Reply With Quote
  #63  
Old 04-21-2007, 07:40 PM
BadgerDog BadgerDog is offline
 
Join Date: Oct 2006
Location: Toronto
Posts: 1,789
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BadgerDog View Post
Installed....


I usually avoid that and only login as Admin.... can I change something someplace to be able to use it under the lower capability?

BTW, here's what I get for loading...

16:57:51 up 194 days, 20:26, 0 users, load average: 0.08, 0.03, 0.01
Dream....

Any advice on what to change so I can use this just as an Admin?

Thanks

Regards,
Badger
Reply With Quote
  #64  
Old 04-21-2007, 10:29 PM
NeRilkA's Avatar
NeRilkA NeRilkA is offline
 
Join Date: Jun 2002
Location: South of France
Posts: 56
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dream View Post
Are you running on unix?

The other problem you have is my bad. You need to run this as a Super Admin or that will happen.
I suppose its unix because the os is linux

I'm sorry I forgot about the Superadmin when i was testing it on the other forum :erm:
Reply With Quote
  #65  
Old 04-22-2007, 12:32 AM
Dream's Avatar
Dream Dream is offline
 
Join Date: Oct 2001
Posts: 2,251
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BadgerDog View Post
Dream....

Any advice on what to change so I can use this just as an Admin?

Thanks

Regards,
Badger
remove this from server_info.php

PHP Code:
// ########################## SUPERADMIN CHECK ############################
if (!in_array($vbulletin->userinfo['userid'], preg_split('#\s*,\s*#s'$vbulletin->config['SpecialUsers']['superadministrators'], -1PREG_SPLIT_NO_EMPTY)) ) {
    
rpm_print_stop_back("You don't have permission to access this page.");

Nerilka, I'm sorry but I don't know why uptime isn't working for you. Do you have access to the server? You could try using uptime in the command line and see if your unix system has this command.
Reply With Quote
  #66  
Old 04-22-2007, 03:08 PM
NeRilkA's Avatar
NeRilkA NeRilkA is offline
 
Join Date: Jun 2002
Location: South of France
Posts: 56
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It doesn't really matter for the uptime, i don't have access to the server anyway

is it the same problem for Server Loads failed ?

thanks for your time
Reply With Quote
  #67  
Old 05-05-2007, 09:49 PM
Dream's Avatar
Dream Dream is offline
 
Join Date: Oct 2001
Posts: 2,251
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Not sure, sorry. I'm not very familiar with Unix commands, I just borrowed some codes from other places to wrap this up for me.
Reply With Quote
  #68  
Old 05-06-2007, 05:15 AM
kelekian kelekian is offline
 
Join Date: Jun 2006
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

server time, uptime, memory usage, free disk space, is coming as blank... :S

someone knows this problem?
Reply With Quote
  #69  
Old 05-06-2007, 09:08 PM
jw00dy's Avatar
jw00dy jw00dy is offline
 
Join Date: Dec 2004
Location: Utah
Posts: 250
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Are you on a dedicated server? If you are not, then it's very very possible this will not work for you. If you are simply leasing some space from someone then it's more then likely that it won't work. It all depends on how they have you setup.
Reply With Quote
  #70  
Old 05-06-2007, 09:12 PM
Dream's Avatar
Dream Dream is offline
 
Join Date: Oct 2001
Posts: 2,251
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Also your exec() PHP function could be disabled by your host.
Reply With Quote
  #71  
Old 05-07-2007, 02:19 PM
kelekian kelekian is offline
 
Join Date: Jun 2006
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by jw00dy View Post
Are you on a dedicated server? If you are not, then it's very very possible this will not work for you. If you are simply leasing some space from someone then it's more then likely that it won't work. It all depends on how they have you setup.
semi-dedicated server...
Reply With Quote
Reply


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 On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:16 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04828 seconds
  • Memory Usage 2,320KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_php
  • (5)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete