REDHAT

De TwisterWiki

Création d'un repository pour yum

Arborescence d'un repo

yum
├── base
│   └── [Distrib_version]
│       └── [arch]
│           ├── monappli-1.0-1.[arch].rpm
│           └── repodata
│               ├── filelists.xml.gz
│               ├── other.xml.gz
│               ├── primary.xml.gz
│               └── repomd.xml
└── updates
   └── [Distrib_version]
       └── [arch]
           ├── monappli-1.0-2.[arch].rpm
           └── repodata
               ├── filelists.xml.gz
               ├── other.xml.gz
               ├── primary.xml.gz
               └── repomd.xml

Création d'un paquet RPM

Arborescence

rpmbuild folder
├── BUILD
│   └── projet
├── BUILDROOT
│   ├── monappli-0.1-1.[arch]
│   │    ├── file1
│   │    ├── file2
│   │    ├── folder1
│   │    └── folder2
│   └── monappli2-0.1-1.[arch]
│       ├── file1
│       ├── file2
│       ├── folder1
│       └── folder2
├── RPMS
│       └── [arch]
│           ├── monappli-0.1-1.[arch].rpm
│           └── monappli2-0.1-1.[arch].rpm
│
├── SOURCES
├── SPECS
│   ├── monappli-0.1-1.specs
│   └── monappli2-0.1-1.specs
├── SRPMS
│   ├── monappli-0.1-1.src.rpm
│   └── monappli2-0.1-1.src.rpm
└── tmp

Création du paquet

  • Compilation pour l'archi noarch
rpmbuild -ba --target=noarch  /SPECS/ouroboros-exploitation.spec
  • Compilation pour l'archi i386
rpmbuild -ba /SPECS/ouroboros-exploitation.spec

Configuration réseau

Ajout de route spécifique pour chaque interface

  • Création d'un fichier /etc/sysconfig/network-scripts/route-ethx
ADDRESS0=172.16.2.0
NETMASK0=255.255.255.0
GATEWAY0=172.16.1.0
ADDRESS1=xxx.xxx.xxx.xxx
NETMASK1=xxx.xxx.xxx.xxx
GATEWAY1=xxx.xxx.xxx.xxx
  • Activation de la route
ifdown ethx
ifup ethx