Wednesday, November 03, 2010

wget files from Oracle edelivery

When you want to install software from Oracle you have the great option you can download all you need from the edelivery website. The issue is that most of the files are quite large and in some cases we are talking about a large amount of very large files.

You can download all the files you need and after you downloaded it transfer it to your target server. However this means that your workstation is busy downloading files while you have your target server sitting idle. If you are in the lucky position that you can create a connection to the internet from your server you can download the files by making use of the wget command. The best option is to run the wget command in the background so you can end your connection and go ahead while your server is downloading the files. We assume that you have a linux server with only a commandline, if you are familiar with the download site from Oracle you know that you have to enter some credentials.

Your information is stored in a cookie on your workstation, so you have to move this cookie information to your server, in our case we have uploaded it to the file cookies.txt in the home of the root user. From the edelivery website we get the URL and we have to modify the URL a bit. In the URL we have some '&' signs which have to be changed to '\&'.

the wget command will become something like the example below:
wget --load-cookies /root/cookies.txt -O -bqc

--load-cookies /root/cookies.txt will state to load a cookie file from the stated location.

-O states the name the file will have to get when it is downloaded.

-bqc states that it will have to run in the background (b), no wget output (q) and it will resume a download if it gets broken (c).

This will make sure that the download will run in the background and you can work on other things while the download is running.

No comments: