본문 바로가기
?

단축키

Prev이전 문서

Next다음 문서

+ - Up Down Comment Print
?

단축키

Prev이전 문서

Next다음 문서

+ - Up Down Comment Print

How to install Java on linux with no Internet connectivity (using local repository)


linux A: running in centos 6.6 and connected to the Internet

linux B: running in centos 6.6 and NOT connected to the Internet


here we download java package with dependencies from linux A which is connected to the Internet then configure local repository in linux B with the packages downloaded via linux A. At last java will be installed with dependencies by yum.


###################################################

# from linux A that is connected to the Internet

###################################################


1. install yum-utils for repotrack

yum install -y yum-utils


2. download packages along with all dependencies

repotrack -a x86_64 -p /tmp/packages createrepo java-1.7.0-openjdk


3. remove packages for i686 due to a bug in repotrack

rm -rf /tmp/packages/*i686.rpm



########################################################

# from laptop that is connected to both linux A and B

########################################################


1. copy the packages dir from linux A to local drive

scp -r user@linuxA:/tmp/packages ./


2. copy the packages dir from local drive to linux B

scp -r ./packages user@linuxA:/tmp/



##############################################

# from linux B NOT connected to the Internet

##############################################


1. install createrepo with its dependencies

cd /tmp/packages

rpm -Uvh deltarpm-*

rpm -Uvh python-deltarpm-*

rpm -Uvh libxml2-*

rpm -Uvh createrepo-*


2. change ownership for packages dir

chown -R root.root /tmp/packages


3. run createrepo to create local repo

createrepo /tmp/packages

chmod -R o-w+r /tmp/packages


4. set the repo configuration file

cat > /etc/yum.repos.d/myrepo.repo

------------------8<--------------------

[local]

name=My Local Repo

baseurl=file:///tmp/packages

enabled=1

gpgcheck=0

------------------8<--------------------


5. install java package

yum install java-1.7.0-openjdk


Title
List of Articles
번호 제목 글쓴이 날짜 조회 수
» How to install Java on linux with no Internet connectivity (using local repository) Hojung 2015.12.22 4071
447 How to install tcpreplay on CentOS 6.5 Hojung 2015.08.21 9145
446 Install et131x network interface driver in CentOS 6 (LW25-BDUO3) file Hojung 2015.07.03 5185
445 How to find CentOS and kernel version Hojung 2015.04.30 4497
444 MD5 Test Hojung 2015.04.01 4691
443 MAC times in Linux (atime, mtime, ctime, crtime, touch, stat, debugfs) Hojung 2015.01.13 5649
442 How to generate a key with passphrase Hojung 2014.11.22 5810
441 Most Common OpenSSL Commands Hojung 2014.11.21 6324
440 How to use screen command Hojung 2014.11.17 4699
439 snorby (on testing) Hojung 2014.11.17 7501
438 APM (Apache + PHP + MySQL) with phpmyadmin in CentOS VM Hojung 2014.11.16 5683
437 10 Ways to Generate a Random Password from the Command Line Hojung 2014.11.16 4914
436 How to increase the size of a Linux LVM by adding a new disk file Hojung 2014.11.14 5160
435 Configuring logrotate for Rails logs file Hojung 2014.11.13 5582
434 Installing Splunk on CentOS file Hojung 2014.10.31 7483
433 Web performance test with ab (ruby web, dd, ab) file Hojung 2014.10.01 6423
432 Web performance test with Pylot (ruby web, dd, pylot) file Hojung 2014.10.01 6002
431 Install and Configure NTP to Synchronize The System Clock (ntpd, ntpdate) Hojung 2014.09.17 5477
430 How to disable IPv6 in CentOS 6 Hojung 2014.09.04 5646
429 IDS with snort in CentOS (Snort, Barnyard2) Hojung 2014.08.19 9056
Board Pagination ‹ Prev 1 2 3 4 5 6 7 8 9 10 ... 23 Next ›
/ 23

Designed by sketchbooks.co.kr / sketchbook5 board skin

나눔글꼴 설치 안내


이 PC에는 나눔글꼴이 설치되어 있지 않습니다.

이 사이트를 나눔글꼴로 보기 위해서는
나눔글꼴을 설치해야 합니다.

설치 취소

Sketchbook5, 스케치북5

Sketchbook5, 스케치북5

Sketchbook5, 스케치북5

Sketchbook5, 스케치북5