administrative Access to linux

Hardware topics that do not fit in one of the other categories

Moderator: Mattk

Post Reply
JulioMelo
Fresh Boarder
Fresh Boarder
Posts: 3
Joined: Mon Aug 26, 2013 2:34 am

administrative Access to linux

Post by JulioMelo » Thu Aug 29, 2013 12:04 pm

Hello everybody.
Now just bought a weather station and in it there is a device known as mateohub linux.

I do not know if it's wrong to ask this question here, if I'm sorry and remove the topic.

Doubt: I can access the linux via ssh with the root account?

Why ask this?

wanted to see a way to integrate with twitter and face book generating a text file and this text file would upload.

If possible I thank very the help and if everything occur as planned make available the solution also.

thank you

wfpost
Platinum Boarder
Platinum Boarder
Posts: 588
Joined: Thu Jun 12, 2008 2:24 pm
Location: HONSOLGEN
Contact:

Re: administrative Access to linux

Post by wfpost » Thu Aug 29, 2013 2:15 pm

JulioMelo wrote:
Doubt: I can access the linux via ssh with the root account?
yes, you can
Attachments
Screen_20130829141209.jpg
Screen_20130829141209.jpg (149.59 KiB) Viewed 3024 times

JulioMelo
Fresh Boarder
Fresh Boarder
Posts: 3
Joined: Mon Aug 26, 2013 2:34 am

Re: administrative Access to linux

Post by JulioMelo » Thu Aug 29, 2013 4:50 pm

wfpost wrote:
JulioMelo wrote:
Doubt: I can access the linux via ssh with the root account?
yes, you can


Thanks for the quick return.

I wonder if you have the username and password.

If you've got to send me?

juliocesarm@gmail.com

Thank you!

wfpost
Platinum Boarder
Platinum Boarder
Posts: 588
Joined: Thu Jun 12, 2008 2:24 pm
Location: HONSOLGEN
Contact:

Re: administrative Access to linux

Post by wfpost » Thu Aug 29, 2013 9:00 pm

username >> root
password >> meteohub

meteohub is the default password of a fresh install
if you had changed the password via the webgui then the new root pw is what you entered there :wink:


ttytter works fine on my meteohub >>>
http://www.floodgap.com/software/ttytter/

also uploading with email to flickr it a good choice as it provides an automatic twitter upload as well >>>
https://twitter.com/honsolgen

e.g. this script uploads and tweets weatherdata from my meteohub and weather conditions catched from wunderground
#!/bin/bash
export LANG=de_DE.UTF-8
cd /tmp
HOUR=$(date +%k)
DAY1=$(date -d today +%A)
lynx -dump '/m.htm' >wshonsolgen.txt
lynx -dump 'http://mobile.wunderground.com/cgi-bin/ ... =landsberg' > show.txt
wget 'http://meteohub/meteograph.cgi?graph=Tweet' --output-document=Tweet.png

DATUM=$(date +'%d/%m/%Y')
TIME=$(date +'%H:%M')
TIME=${TIME:0:4}0

T=$(awk 'NR==2 { print $2 }' wshonsolgen.txt)
T=${T%??}
T=$T'°C'
DEW=$(awk 'NR==3 { print $2,$3 }' wshonsolgen.txt)
TMIN=$(awk 'NR==4 { print $2,$3 }' wshonsolgen.txt)
TMAX=$(awk 'NR==5 { print $2,$3 }' wshonsolgen.txt)
TSOIL=$(awk 'NR==7 { print $1,$2,$3 }' wshonsolgen.txt)
TWZ=$(awk 'NR==8 { print $2,$3 }' wshonsolgen.txt)
TGH=$(awk 'NR==11 { print $2,$3 }' wshonsolgen.txt)
SOL=$(awk 'NR==13 { print $3,$4 }' wshonsolgen.txt)
UV=$(awk 'NR==14 { print $3 }' wshonsolgen.txt)
if [ "$UV" = '0.0' ]; then UV=""; else UV="UV "$UV; fi
PRESS=$(awk 'NR==15 { print $2 }' wshonsolgen.txt)
BAROTREND=$(awk 'NR==15 { print $4 }' wshonsolgen.txt)
BAROTREND=$(echo $BAROTREND | sed 's/\./,/')
BAROTREND=$(printf "%.1f\n" $BAROTREND)
BAROTREND=$(echo $BAROTREND | sed 's/\,/./')
if (( $(bc <<< "$BAROTREND >= 0.0") > 0 )); then BAROTREND="+"$BAROTREND; fi
BAROVP=$(awk 'NR==15 { print $4 }' wshonsolgen.txt)
HUM=$(awk 'NR==18 { print $3 }' wshonsolgen.txt)
WIND1=$(awk 'NR==19 { print $4 }' wshonsolgen.txt)
WIND1=$(echo $WIND1 | sed 's/\./,/')
WIND=$(printf "%.0f\n" $WIND1)
WIND=${WIND}" km/h"
if [ "$WIND" = '0.0 km/h' ]; then WIND="calm"; fi
WINDDIR=$(awk 'NR==20 { print $3 }' wshonsolgen.txt)
REGEN=$(awk 'NR==21 { print $5 }' wshonsolgen.txt)
REGEN=$(echo $REGEN | sed 's/\./,/')
REGEN=$(printf "%.1f\n" $REGEN)
REGEN=$(echo $REGEN | sed 's/\,/./')
REGEN=$REGEN'l'

sed -n '/Conditions/,$p' <show.txt >cc.txt
CC=$(awk 'NR==1 { print $2,$3 }' cc.txt)
sed -n '/Forecast as/,$p' <show.txt >forecast.txt
sed -i "s/° C./°C/g" forecast.txt
FC=$(awk 'NR==12 { print $1,$2,$3,$4,$5,$6,$7 }' forecast.txt)
FCN=$(awk 'NR==14 { print $1,$2,$3,$4,$5,$6,$7 }' forecast.txt)

if (( $(bc <<< "$BAROVP >= -0.7") > 0 )); then BARO="↔" BAROTXT="↔ steady"; fi
if (( $(bc <<< "$BAROVP >= 0.7") > 0 )); then BARO="↗" BAROTXT="↗ rising"; fi
if (( $(bc <<< "$BAROVP <= -0.7") > 0 )); then BARO="↘" BAROTXT="↘ falling"; fi

if [ $HOUR -lt 8 ] && [ $HOUR -gt 0 ]
then

sendemail -f "ALIX <email>" -o message-content-type=auto -a /tmp/Tweet.png -t accountwithin2twitter@photos.flickr.com -u "$TIME ☀ $CC $BARO $T rh $HUM% | $WIND - $WINDDIR | $PRESS hPa $BAROTXT $BAROTREND /3h | ☂/day $REGEN #wetter http://www.wetteronline.de/wetter/buchloe" -m "$TIME &#9728; Forecast: $FC ... Tomorrow night: $FCN" -s smtp.emailserver.net:25 -xu email -xp password

else

sendemail -f "ALIX <email>" -o message-content-type=auto -a /tmp/Tweet.png -t accountwithin2twitter@photos.flickr.com -u "$TIME ☀ $CC $BARO $T rh $HUM% | $WIND - $WINDDIR | $PRESS hPa $BAROTXT $BAROTREND /3h | ☂/day $REGEN #weather http://www.wetteronline.de/wetter/buchloe" -m "$TIME &#9728; Forecast: $FC ... Tomorrow night: $FCN" -s smtp.emailserver.net:25 -xu email -xp password

fi
Attachments
Screen_20130829213431.jpg
Screen_20130829213431.jpg (103.71 KiB) Viewed 3016 times

Post Reply