Jump to content
Sign in to follow this  
Followers 0

Application: Linux System Script

71 posts in this topic

Posted

Awesome can you try this one

http://www.haggistech.co.uk/ostest.tar.gz

its the same stats file inside just modified

Share this post


Link to post
Share on other sites

Posted

[quote name='Haggis' timestamp='1356305777' post='595411880']Awesome can you try this one [/quote]
Little better, picked up the distro name this time correctly, although still showing both Ubuntu and Debian ASCII art. Note a new line of text from lsb_release above the two errors.

[code]root@server7:~# ./stats.sh
No LSB modules are available.
./stats.sh: line 242: xdpyinfo: command not found
./stats.sh: line 313: mate-session: command not found


..''''''..
.;::::::::::::::;.
.;::::::::::::::'.':::;.
.;::::::::;,'..';. .::::;.
.:::::::,.,. ....:::::::.
.:::::::. :;::::,. .:::::::.
;:::::: .::::::::::. ::::::;
:::. .' ::::::::::::...,::::::
:::. .' ::::::::::::...,::::::
;:::::: .::::::::::. ::::::;
.:::::::. :,;::;,. .:::::::.
.:::::::;.;. ....:::::::.
;::::::::;,'..';. .::::;
.;::::::::::::::'.':::;.
.,::::::::::::::,.
...''''...


_,met$$$$$gg.
,g$$$$$$$$$$$$$$$P.
,g$$P$$ $$$Y$$.$.
,$$P` `$$$.
,$$P ,ggs. `$$b:
d$$` ,$P$` . $$$
$$P d$` , $$P
$$: $$. - ,d$$`
$$; Y$b._ _,d$P`
Y$$. .`$Y$$$$P$`
`$$b $-.__
`Y$$b
`Y$$.
`$$b.
`Y$$b.
`$Y$b._
`$$$$


OS: Ubuntu 12.04.1 LTS
Hostname: server7
CPU: Pentium III (Coppermine)
RAM (used / total): 173 / 1001 Mb
Desktop Enviroment: Not Found
Logged in as: root
Kernel: 3.2.0-35-generic-pae
Resolution: pixels
Load Averages: 0.31, 0.14, 0.07
Top Process (by memory use): /usr/sbin/mysqld[/code]

Share this post


Link to post
Share on other sites

Posted

yeah the NO LSB modules is just because nothing is installed maybe due to X not being there but not sure


sorry to ask again but can you try this one

http://www.haggistech.co.uk/ubuntutest.tar.gz

Share this post


Link to post
Share on other sites

Posted

[quote name='Haggis' timestamp='1356307092' post='595411896']yeah the NO LSB modules is just because nothing is installed maybe due to X not being there but not sure
sorry to ask again but can you try this one[/quote]
Heh I'd suspect not too many people with server-only installs are going to worry about this sort of script anyway, I was just trying it out of curiosity. It's not a bother, not doing anything important today. I see you got the stray Debian logo out of it this time.

[code]root@server7:~# ./stats.sh
No LSB modules are available.
./stats.sh: line 242: xdpyinfo: command not found
./stats.sh: line 313: mate-session: command not found


..''''''..
.;::::::::::::::;.
.;::::::::::::::'.':::;.
.;::::::::;,'..';. .::::;.
.:::::::,.,. ....:::::::.
.:::::::. :;::::,. .:::::::.
;:::::: .::::::::::. ::::::;
:::. .' ::::::::::::...,::::::
:::. .' ::::::::::::...,::::::
;:::::: .::::::::::. ::::::;
.:::::::. :,;::;,. .:::::::.
.:::::::;.;. ....:::::::.
;::::::::;,'..';. .::::;
.;::::::::::::::'.':::;.
.,::::::::::::::,.
...''''...


OS: Ubuntu 12.04.1 LTS
Hostname: server7
CPU: Pentium III (Coppermine)
RAM (used / total): 173 / 1001 Mb
Desktop Enviroment: Not Found
Logged in as: root
Kernel: 3.2.0-35-generic-pae
Resolution: pixels
Load Averages: 0.20, 0.08, 0.06
Top Process (by memory use): /usr/sbin/mysqld
[/code]

Share this post


Link to post
Share on other sites

Posted

dude can you do

[CODE]
echo $display
[/CODE]

and let me know what it says

Share this post


Link to post
Share on other sites

Posted

[quote name='Haggis' timestamp='1356308100' post='595411910']echo $display[/quote]

Non-existant.

[code]root@server7:~# echo $DISPLAY

root@server7:~#[/code]

[i]Edit[/i] Derp -- I'm going through SSH, no forwarding, so that won't exist I think. Enabled X forwarding in my client, new result. It's my day off, I left the brain at my other desk.

[code]root@server7:~# echo $DISPLAY
localhost:10.0[/code]

Share this post


Link to post
Share on other sites

Posted

ok cool
with x forwarding are you still getting the same two errors?

Share this post


Link to post
Share on other sites

Posted

[quote name='Haggis' timestamp='1356308602' post='595411918']with x forwarding are you still getting the same two errors?[/quote]

Yes -- X is enabled in the client, but it's still not actually installed on the server, nor do I have the Mate desktop. Those two will always return errors for setups like mine. Same result in the script as in my previous post. For me I'm not terribly worried about it, just passed it along in case you're hate leaving loose ends like I do.. I'd guess not a whole lot of interest in something like this for a server install.. they make for boring screenshots. :D
[url="http://www.neowin.net/forum/topic/1125048-application-linux-system-script/page__st__15__p__595411898#entry595411898"]http://www.neowin.ne...#entry595411898[/url]

Share this post


Link to post
Share on other sites

Posted

ok cool

gonna put this down to your ssh into the box then lol

Share this post


Link to post
Share on other sites

Posted

Hi Haggis, finally got something working to test your script.

Seems to get a bit confused over Xubuntu:

Share this post


Link to post
Share on other sites

Posted

hmmm i though i had fixed this lol

*buntus carry over the /etc/debian_version

this is why it picks up as debian

when did you download it?

download this one and try it maybe i forgot to update the file

http://www.haggistech.co.uk/ubuntutest.tar.gz

Share this post


Link to post
Share on other sites

Posted

I downloaded it on the 29th December. I just rebuilt my Hyper-V server last night so I'll see if I can test later on.

Share this post


Link to post
Share on other sites

Posted

Cool if it does the same let me know and i will fix it :)

Share this post


Link to post
Share on other sites

Posted

Yep. all working now :)

Share this post


Link to post
Share on other sites

Posted

Awesome :)

updated the file online

Share this post


Link to post
Share on other sites

Posted

So a bit of a noob here.

How do I get this to work?

Share this post


Link to post
Share on other sites

Posted

[quote name='bman' timestamp='1357157145' post='595428830']How do I get this to work?[/quote]
Mark the script as executable (chmod +x stats.sh) and then just do a ./stats.sh in a console.
1 person likes this

Share this post


Link to post
Share on other sites

Posted

yeah as max says

open a terminal

go to the filder the script is in so for example

[CODE]cd /home/haggis[/CODE]

do

[CODE]chmod +x stats.sh[/CODE]

then do

[CODE]./stats.sh[/CODE]

Share this post


Link to post
Share on other sites

Posted

Thanks.

This might sound stupid but when I CD my directory, says it's "No such file or directory"

I am pretty sure it's correct. I have it in my Documents folder /home/bman/Documents

What am I doing wrong?

Share this post


Link to post
Share on other sites

Posted

[quote name='bman' timestamp='1357159381' post='595428898']This might sound stupid but when I CD my directory, says it's "No such file or directory"[/quote]
Is the capitalization correct when you're typing it? *Nix is case sensitive, throws me off all the time. "documents" and "Documents" are two different directories as far as Linux is concerned where out of the box Windows won't care either way, easy mistake to make if you bounce back and forth a lot. Most file managers have a "Open terminal here" sort of context menu too if it helps any, depends on which file manager you're using.. some aren't as flexible/convenient as others.

Share this post


Link to post
Share on other sites

Posted

I have tried it both ways without luck.

And no option like that in my file manager. Default Ubuntu 12.04...

Best file manager? Any out there with tabs?

Share this post


Link to post
Share on other sites

Posted

[quote name='bman' timestamp='1357161482' post='595428954']
I have tried it both ways without luck.

And no option like that in my file manager. Default Ubuntu 12.04...

Best file manager? Any out there with tabs?
[/quote]

Nautilus - the default file manager in Ubuntu - is my favorite file manager, and it [i]does[/i] have tabs. You can either go to "File->New Tab" to open a new tab or use the keyboard shortcut "Ctrl+T". You can also add an "Open in Terminal" option to the Nautilus context menu as described [url="http://askubuntu.com/questions/207442/how-to-add-open-terminal-here-to-nautilus-context-menu"]here[/url].

Share this post


Link to post
Share on other sites

Posted

Thanks guys, got the open in terminal working, and got the script working with that.

Awesome!

Share this post


Link to post
Share on other sites

Posted

post a screenshot if u can :)

Share this post


Link to post
Share on other sites

Posted

Just a fresh install. Will post in that thread :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

  • Recently Browsing   0 members

    No registered users viewing this page.