Pokazywanie postów oznaczonych etykietą Technical. Pokaż wszystkie posty
Pokazywanie postów oznaczonych etykietą Technical. Pokaż wszystkie posty

czwartek, marca 17, 2011

A nice flick with PLUS GSM SMS gateways (an old one)

I use this functionality occasionally, but find it very useful from time to time.
The following instructions are provided (mostly) for users of Plus GSM polish cellular operator.

Sending a text message (SMS) to an e-mail.

To send a text message from a mobile phone (in PLUS GSM network) to an e-mail (any provider), you need to send text directly to no. 119999 (double one and four nines). The message should consist of the following:

At the beginning of message you should put recipient e-mail address in round brackets, next the topic of the message, also in round brackets (this one's optional, the message doesn't need to have a topic), and finally the message contents. Here's an example of correctly prepared message:

(user@domain) (MessageTopic) Here's the message...

Maximal text message length for a phone is 160 characters (including the e-mail adress).
To have the ability to use this functionality in your phone, set the standard Text Message Center number for Plus GSM network, that is by default: +48 601 000 310

The number of e-mail of messages sent this way is unlimited. The fee for each message is equal to fee for an ordinary text message, accordingly to your price plan.

And the other way around...
In Plus GSM network it is also possible to receive messages sent from any e-mail box directly to your mobile phone, and read it as ordinary text message (no multimedia attachments are allowed).

Sending an e-mail to Plus GSM phone number as an ordinary text message (SMS).

You can send an e-mail to Plus GSM network user by setting the mail recipient address to +48xxxxxxxxx@text.plusgsm.pl (where each x sign marks the digit in
9-position recipient's phone number. The +48 is the international country prefix for Poland). Some e-mail box providers (e.g. o2.pl) do not recognize address with leading "+" sign as correct. In such case, just drop it :) The "48" at the beginnng of the address will do just fine.

Maximal e-mail message length is 620 characters ([plain text! watch out for HTML e-mail encoding] including the recipient address and message topic). If the message length is over 160 characters, the system will automatically divide it into few smaller ones.

The number of e-mails sent this way is limited, but no further information about specific numbers is given by the network operator.
The gateway is for non-commercial use only and the operator (Polkomtel S.A.) takes no responsibility for other provider's services based on this gateway.

Hope it works for you as fine, as it works for me.

wtorek, lutego 01, 2011

How to boot SystemRescueCD using PXE?

OK, so i thought of using PXE to boot some OSes mainly because burning/finding new XP installation disk takes too log and it would be cool to just backup windows using nothing more than AC power cable and 100Base-T.

First thing i did was to install tftp-hpa - you NEED tftp server, and tftp-hpa had smallest number of dependencies on my gentoo box. As configuration is all self explanatory and contained in one file, i will not divulge in it. If you got any problems you can try to ask them here, but, really, better put your googles on :> (or bing all info you need)

Second thing is to setup your DHCP server to provide vital options to PXE client, mainly IP address, TFTP server addres, and main PXE file to boot from. As i have 10.0.0.0/24 network with WRT54GL (DD-WRT on it) and i'm using DNSMASQ, i added this line to config:
dhcp-boot=pxelinux.0,cid,10.0.0.3


Where cid is hostname of my server machine, 10.0.0.3 is it's IP address and pxelinux.0 is bootloader file.

Third thing to prepare is nfs server (and/or SAMBA for windows) to mount root partition. There's also possibility of using http or tftp again, but as i already had nfs to mout some shares, i worked with it.

This is where all oh-so-easy linux configuration ends and heavy wizardry of PXE starts. As for today, i booted only SystemRescueCD - it was the easiest and there were bunch of helpful howtos on the net. Plus, it enabled me to boot with sane OS, has some nice tools (like gparted - no more evil windows partitioner program which gives me creeps even thinking about it). There's also ntpasswd and memtest86 and docache and ntfs3g and.... Well, imo it's best to use as starter.

I ended up needing to burn at least one disc with SystemRescueCD. It has PXE server integrated and ready-to-use filesystem which i copied. So i burned it, booted from it and did something like:

# On SysResc Workstation:

scp -r /tftpboot normaluser@mytftpserver:/.

# On Server, as root:

cd /files/Install/tftpboot
mkdir sysresccd
mv /home/normaluser/tftpboot/* sysresccd/
chown -R nobody:nobody sysresccd/
rmdir /home/normaluser/tftpboot


Now on to install PXE bootloader. I ended up finding it on sysresCD/isolinux/pxelinux.0 - the one from syslinux i tried didn't work. I copied it to /files/install/tftproot/ (to which from now on i'll refer as $tftproot). Next thing was to make simple PXE boot menu:
mkdir $tftproot/pxelinux.cfg

touch $tftproot/pxelinux.cfg/default

Then i fired up my favourite VI-like editor (vim) and copied menu like this:
PROMPT 1
TIMEOUT 15
ONTIMEOUT sysresccd

MENU DEFAULT sysreccd
MENU TITLE PXE Cid

LABEL ubuntu
MENU LABEL Ubuntu boot disk
COM32 ubuntu-installer/i386/boot-screens/menu.c32
APPEND ubuntu-installer/i386/boot-screens/menu.cfg

LABEL sysresccd
MENU LABEL System Rescue CD
COM32 sysresccd/isolinux/menu.c32
APPEND sysresccd/isolinux/isolinux.cfg

MENU END


Even though ubuntu part is missing (no files to boot it) it all went just fine (a little patience and it will hop into sysrescd menu).
As i used older guide (for brand new SystemRescueCD 2.0.0) i ended up tweaking $tftproot/sysresccd/isolinux/isolinux.cfg as well. Main things to remember:
  • All KERNEL lines must be updated, with paths to actual files using $tftproot as / - for me it was like this: LINUX sysresccd/rescuecd
  • Same with INITRD lines - INITRD sysresccd/initram.igz
  • All APPEND lines refering to booting normal linux (like rescuecd,rescue64,altker32,altker64) MUST contain nfsboot line (path to NFS share with sysrcd.dat file) for me: netboot=10.0.0.3:/files/Install/tftproot/sysresccd - there's no DNS at this point, so only IP address
And that's it! I hope that nothing was forgotten - just remember to start tftp-hpa and nfs services :P
Next time i'll try to start Windows XP installation from PXE on linux (nlite image is compiling now, keep your thumbs up!). If You have any ideas/better ways to do this, please share them!
During my experiments i used those sites as help in putting it together:
  • http://harkko.lattu.biz/notes/pxe-boot_system_rescue_cd.html
  • http://www.sysresccd.org/Sysresccd-manual-en_PXE_network_booting
  • http://pxe.dev.aboveaverageurl.com/index.php/Main_Page
  • http://en.wikipedia.org/wiki/Preboot_Execution_Environment

poniedziałek, września 20, 2010

Wind of change?

Ok, after looooong time of absence i tought of changing this blog to some kind of "technical diary". The plan is to write about every problem i run into when dealing with computers and software, so whenever I (or You, if somebody other than me will ever read this) ever encounter same problem again, we'll know what to do.

I also think it's good place to polish my english, but only after I install new dictionary to my firefox. For the time being, sorry for all mistakes i'll make.