In this guide I will describe you some different ways to download files from RapidShare in Linux using your Premium Account. I believe it's rather boring everytime to have to visit your RapidShare page account when you click on a link in order to download a file. I will show you how to use either terminal programs or how to do it the GUI way. Of course you must have enabled the Direct Downloads option in your Premium Account options page. So let's move on!
Note: Read my new How to easily download RapidShare files in Linux by using FreeRapid Downloader. It describes how to use your RapidShare Premium Account and download RapidShare files by using a download manager with Graphical Interface called FreeRapid Downloader.
-
Using wget
wget \
--save-cookies ~/.cookies/rapidshare \
--post-data "login=USERNAME&password=PASSWORD" \
--no-check-certificate \
-O - \
https://ssl.rapidshare.com/premzone.html \
> /dev/null --save-cookies defines the location the cookie will be stored
--post-data provides the login form with your account's data
--no-check-certificate don't validate the server's certificate
-O downloads the html page to get the cookie and then it deletes it by redirecting it to /dev/null
Of course you must replace USERNAME and PASSWORD with your account details.
**Note: If you are using a wget prior to 1.10.2 the --no-check-certificate option is not needed.
Now each time you want to download a file you just have to type:
wget -c --load-cookies ~/.cookies/rapidshare url
However this is incovenient if you have multiple files to download. In that case we will create a script to automate the job. Create a new text file and paste the following lines:
#!/bin/bash
for url in `cat $1`
do
wget -c --load-cookies ~/.cookies/rapidshare $url
done
Save it as downloader.sh and exit. Next we must make it executable, so type:
chmod +x downloader.sh
Now copy all the links of the rapidshare files you want to download and paste them in a file named urls the one under the other.
To download them one by one type:
./downloader.sh urls
-
Using aria2c
aria2c --http-user=USERNAME --http-passwd=PASSWORD -i urls -j 2 -s 4
-i urls urls is a text file containing all the links of the the files you want to download one under the other
-j 2 number of simultanious downloads (default value is 5)
-s 4 number of connections for each file
-
For KDE users
-
For GNOME users
Open a terminal and type:
wget \
--save-cookies ~/.cookies/rapidshare \
--post-data "login=USERNAME&password=PASSWORD" \
--no-check-certificate \
-O - \
https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi \
> /dev/null Rapidshare cookie will be saved in ~/.cookies/rapidshare. Next install flashgot extension for Firefox from here . After that restart Firefox and go to Tools -> FlashGot -> More Options... and in the General tab select "Built in" as Download Manager and click the Add button.

Finally set the Executable path, Command line arguments template and Show in context menu as in the screenshot below. Now each time you want to download a file just right click on it and choose FlashGot Selection.

Trackback(0)
TrackBack URI for this entryComments (36)
Subscribe to this comment's feedi dont have a premium account
...
...
I didn't understand where you got the error. Do you have a directory named .cookies inside your home directory? It is hidden. In which directory did you check for the rapidshare cookie?
...
i am also getting the same problems as larababa, using the "for gnome users" part of the guide.
checked my home directory and the .cookies directory does not exist.
at the end of the process i get this:
Cannot open cookies file `/root/.cookies/rapidshare': No such file or directory
any help would be great
...
mkdir ~/.cookies
Type this first and then the wget command.
...
http://fedoracoreproject.blogspot.com/2009/03/linux-command-line-tool-to-download.html
download only HTML pages
I used your script, but I've got only HTML pages (not files) from rapidshare (HTML pages with buttons to free or premium download)
Do you know how to download files ?
Thanks a lot.
...
...
As I understand from axel's site currently it doesn't officially support loading of cookies. A patch is submitted but it hasn't been added to the stable package. You can read more and apply the patch on your own here: axel firefox cookie support
r434rf
make a rs.txt file in a dir and put the rs links in it then excecute this cmd
:)
Thanks
Nice one!!
For some reason aria2c doesn't work on my Desktop anymore [only on my server] and wget with a cookie never worked.
That's a nice tip, withe --auth-no-challenge option, works a treat on my desktop!
Thanks again.
...
http://www.econowics.com/linux...tu-linux/
Being a linux noob..I'm running Mint 7..I found this easy to install and use..for paid and free account of many hosting sites...works great!
...
http://www.getdeb.net/app/Tucan
...
rapidshare script for free users
Here's a small linux/windows rapidshare download script which works for free users:
http://sniper11powers.blogspot...cript.html
Hope you like it too
...
For the time being I am pretty satisfied with Firefox, flashgot and kget!
...
Linux Script to Download RapidShare Link's into TorrentFlux
don't forget to chmod 700 in order to execute
#!/bin/sh
#########################################
#Script Setings - Change as needed. #
#########################################
export tdir='/usr/local/torrentflux' #Directory where TorrentFlux downloads are stored.
export user='root' #TorrentFlux User account to download files to.
export rsuser='99999999' #RapidShare Username (you must be premium user)
export rspass='passowrd' #RapidShare Password
#########################################
# Do not change anything below here. #
#########################################
export dtime=$(date +"%m-%d-%y.%H.%M.%S")
export urls='urls.'$dtime
export sdir=$(pwd)
export udir=$sdir'/downloadurls'
function ConfirmOrExit() {
while true
do
echo -n "Please confirm (y or n) :"
read CONFIRM
case $CONFIRM in
y|Y|YES|yes|Yes) break ;;
n|N|no|NO|No)
echo Aborting - you entered $CONFIRM
exit
;;
*) echo Please enter only y or n
esac
done
echo You entered $CONFIRM. Continuing ...
}
function dname() {
while true
do
echo '----- Enter the name of the Directory for the new torrent. ------'
echo '----- Be sure to use the proper syntax for directories in Linux. ------'
read dirname
echo "###############################################"
echo "You Entered: $dirname"
echo "###############################################"
echo '----- Is this Correct (Y or N) ------'
read CONFIRM
case $CONFIRM in
n|N|no|NO|No) ;;
y|Y|YES|yes|Yes)
break
;;
exit) exit
;;
*) echo 'Please enter only "Yes" or "No"'
esac
done
}
function setcookie() {
echo '############################'
echo 'Setting RapidShare Cookie'
echo '############################'
echo '---------------------------'
mkdir -p ~/.cookies
wget
--save-cookies ~/.cookies/rapidshare
--post-data 'login='$rsuser'&password='$rspass
https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi
< /dev/null
}
function downloadrs () {
for url in `cat $udir/$urls`
do
wget -c --load-cookies ~/.cookies/rapidshare $url
done
}
function setudir() {
echo '---------------------------'
echo "Setting up Directories"
echo '---------------------------'
mkdir -p $udir
echo '######################################################
#######'
echo "The current time stamp is "$dtime
echo "The working URL file will be "$udir'/'$urls
echo '######################################################
#######'
ConfirmOrExit
}
function addurls () {
echo " #######################################################
#####"
echo "## Next, you will need to paste the list of URL's into ##"
echo "## the VI editor. Consult VI documentation for info on ##"
echo "## how to use VI. Don't forget to Write/Quit when done. ##"
echo " #######################################################
#####"
ConfirmOrExit
vi $udir'/'$urls
}
setcookie
setudir
dname
addurls
clear
echo " #######################################################
##############"
echo "## Now we will Download the list of URL's into the TF Directory. ##"
echo " #######################################################
##############"
cd $tdir'/'$user
mkdir $dirname
chmod 777 $dirname
cd $dirname
downloadrs
chmod 777 *
ls -l -h
...
Thanks! ...
...
Tucan
Thank you for this
Small update
https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi
changes to
https://ssl.rapidshare.com/premzone.html
Write comment