Archives pour la catégorie UBUNTU

Viber installation

L ‘ installation via dpkg ou gdebi se termine , mais viber ne se lance pas

« chown: cannot access ‘/root/Documents/ViberDownloads’: No such file or directory

1 verifier les dependances

ldd viber
libstdc++.so.6: version `GLIBCXX_3.4.20′ not found

G..LIBCXX.. means « gnu libc++ », which we know as libstdc++, a gcc library.
GLIBCXX_3.4.20 is an object from the gcc-4.9.x libstdc++.so.6.0.20
The trick is to find a libstdc++-4.9.x

2 installation gcc 4.9
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install gcc-4.9 g++-4.9

montage vhd avec qemu

sudo apt-get install qemu-kvm qemu virt-manager virt-viewer libvirt-bin

modprobe nbd

qemu-nbd -c /dev/nbd0 <vdi-file>

mount /dev/nbd0p1 /mnt

umount /mnt
qemu-nbd -d /dev/nbd0

qemu-nbd —help
Usage: qemu-nbd [OPTIONS] FILE
QEMU Disk Network Block Device Server

-h, —help display this help and exit
-V, —version output version information and exit

Connection properties:
-p, —port=PORT port to listen on (default `10809’)
-b, —bind=IFACE interface to bind to (default `0.0.0.0’)
-k, —socket=PATH path to the unix socket
(default ‘/var/lock/qemu-nbd-DEVICE’)
-e, —shared=NUM device can be shared by NUM clients (default ‘1’)
-t, —persistent don’t exit on the last connection
-v, —verbose display extra debugging information
Exposing part of the image:
-o, —offset=OFFSET offset into the image
-P, —partition=NUM only expose partition NUM

Kernel NBD client support:
-c, —connect=DEV connect FILE to the local NBD device DEV
-d, —disconnect disconnect the specified device

Block device options:
-f, —format=FORMAT set image format (raw, qcow2, …)
-r, —read-only export read-only
-s, —snapshot use FILE as an external snapshot, create a temporary
file with backing_file=FILE, redirect the write to
the temporary one
-l, —load-snapshot=SNAPSHOT_PARAM
load an internal snapshot inside FILE and export it
as an read-only device, SNAPSHOT_PARAM format is
‘snapshot.id=[ID],snapshot.name=[NAME]’, or
‘[ID_OR_NAME]’
-n, —nocache disable host cache
—cache=MODE set cache mode (none, writeback, …)
—aio=MODE set AIO mode (native or threads)
—discard=MODE set discard mode (ignore, unmap)
—detect-zeroes=MODE set detect-zeroes mode (off, on, unmap)

Drobpox as a service

Installation

1 telechargement du paquet
cd ~
curl -Lo dropbox-linux-x86_64.tar.gz https://www.dropbox.com/download?plat=lnx.x86_64
sudo mkdir -p /opt/dropbox sudo tar xzfv dropbox-linux-x86_64.tar.gz –strip 1 -C /opt/dropbox

2 lancement du client dropbox
/opt/dropbox/dropboxd
se connecter au compte en ligne puis quitter
Ctrl-C

3 Mise en place du script de demarrage automatique
telechargement du script dans /etc/init.d
cd ~
sudo curl -o /etc/init.d/dropbox https://gist.githubusercontent.com/thisismitch/d0133d91452585ae2adc/raw/699e7909bdae922201b8069fde3011bbf2062048/dropbox

sudo chmod +x /etc/init.d/dropbox

4 creation du fichier dropbox avec ajout du compte systeme
sudo nano /etc/default/dropbox
DROPBOX_USERS= »compte1″

5 Demarrage du service dropbox et configuration du demarrage automatique
sudo service dropbox start
sudo update-rc.d dropbox defaults

AJOUT COMPTE SUPPLEMENTAIRE

lancement du client dropbox
/opt/dropbox/dropboxd

ajout du compte systeme dans le fichier dropbox
sudo nano /etc/default/dropbox
DROPBOX_USERS= »compte1 compte2″

sudo service dropbox restart

DECONNEXION D’UN COMPTE

sudo service dropbox stop

suppression du dossier dropbox
sudo rm -r ~/compte2/Dropbox

sudo service dropbox start

TermRecord

TermRecord permet d’enregistrer la séquence terminal dans un fichier html

installation python et pip (Pip est un système de gestion de paquets utilisé pour installer et gérer des librairies écrites en Python. Pip empêche les installations partielles en annonçant toutes les exigences avant l’installation)

sudo apt-get install python-pip

*installation TermRecord

sudo pip install TermRecord

*lancement d ‘un enregistrement

TermRecord -o /tmp/session.html

Veeam agent linux sur ubuntu

1-Installation de l’agent veeam linux

 dpkg -i ./veeam-release* && apt-get update

2-creation du repertoire backup

 veeamconfig repository create --name Backup --location /media/data/test

lister les repertoires backup

 veeamconfig repository list 

Name ID Location Type Backup server
Backup {4939770e-9ab9-40e7-9998-bac778484078} /media/data/test local

2-Creation job filelevel

 veeamconfig job create filelevel --name jobtest1 --reponame Backup --includedirs /home/test/Documents 
 Job has been created successfully.

Info sur le job

 veeamconfig job info --name jobtest1 

Backup job
ID: {edc9a98f-06f0-4d0d-972b-716aa3027325}
Name: jobtest1
Repository ID: {4939770e-9ab9-40e7-9998-bac778484078}
Repository name: Backup
Creation time: 2017-12-13 08:49:06
Options:
Compression: Lz4
Max Points: 14
File system indexing is disabled
Objects for backup:
Include Directory: /home/test/Documents

Demarrage du job

 veeamconfig job start --name jobtest1 

Backup job has been started.
Session ID: [{6050632c-a0c1-46f7-837c-44599a7659ee}].
Logs stored in: [/var/log/veeam/Backup/jobtest1/Session20171213_085051{6050632
c-a0c1-46f7-837c-44599a7659ee}]

voir backup

 veeamconfig backup list 

Job name Backup ID Repository Created at
Predator-G3600 jobtest1 {64b90e30-a5b7-453f-ab05-f9a608269a96} Backup 2017-12-13 08:50

 veeamconfig backup show --id 64b90e30-a5b7-453f-ab05-f9a608269a96} 

Machine name: Predator-G3600 jobtest1
File-level backup
Backed up: /home/test/Documents

MONTAGE BACKUP

 veeamconfig backup mount --id 64b90e30-a5b7-453f-ab05-f9a608269a96 --mountdir /mnt/backup

Backup has been mounted.
Session ID: [{2e8ce07e-c0f9-4b3f-9e17-399e1924bee1}].
Logs stored in: [/var/log/veeam/Mount/Session20171213_090000{2e8ce07e-c0f9-4b3f-9e17-399e1924bee1}].

 ls -la /mnt/backup/FileLevelBackup_0/ 

total 28
drwxr-xr-x 4 root root 4096 déc. 13 08:51 .
drwxr-xr-x 3 root root 4096 déc. 13 09:00 ..
drwxr-xr-x 3 root root 4096 déc. 12 21:47 home
drwx——— 2 root root 16384 déc. 13 08:51 lost+found

EXPORT VHD d’un volume sauvegardé

 veeamconfig backup export --id 64b90e30-a5b7-453f-ab05-f9a608269a96 --outdir /media/DiskData/veeamvhd 

Export has been started.
Session ID: [{9f9c8425-7fc8-4dbb-bd25-844c0bf0aad8}].
Logs stored in: [/var/log/veeam/Export/Session20171213_090754{9f9c8425-7fc8-4dbb-bd25-844c0bf0aad8}].

voir process export

 veeamconfig session log --id 9f9c8425-7fc8-4dbb-bd25-844c0bf0aad8

My Block Note