Four, Spring Security certification and authorization-dynamic authorization solution Still

2023-01-22   ES  

Installation environment:

  1. ubuntu 16.04 LTS

  2. A computer to be cloned, a original Ubuntu16.04 computer

Installation process:
1. Install Ubuntu16.04 LTS in the new computer (this article mainly introduces the cloning of the system. For the initial installation, you will not repeat it here. Please make sure you have root permissions)
2. Related files (including configuration, software, files, etc.) using the TAR compression source computer (including configuration, software, files, etc.)
tar -zcpPf /media/zhoudazhuang/NEWSMY/ubuntu.tar.gz --exclude=/proc --exclude=/lost+found --exclude=/media/zhoudazhuang/NEWSMY/ubuntu.tar.gz --exclude=/media --exclude=/mnt --exclude=/sys / >/dev/nulll
Note: The F parameter needs to be placed at the end, otherwise it will be unable to operate. The same is true when the decompression operation is performed. Using>/dev/null means that the standard output is placed in the black hole, that is, the standard output will not be output. See the standard error output of the console
-Z use gzip compression
-C CREATE Create a file
-p maintain the attribute of the original file
-p uses absolute path compression
-F using file name
-exclude is to eliminate files, and the files of this part will not compress
3. Back up the/BOOT and/ETC/FSTAB folders of the new installation system,/boot to record the startup of their respective computers, such as GRUB information,/ETC/FSTAB records the partitioning information. Can’t enter the system.
tar -zcvpf bootandfstab.tar.gz /boot /etc/fstab
4. TAR decompression ubuntu.tar.gz to the new system/directory

`tar -zxvpf ubuntu.tar.gz -c /` 

 -C means the absolute path of decompression use

5. Use the previous method to restore the previously backup/boot and/ETC/FSTAB directory

`tar -zxvpf bootandfstab.tar.gz -C /`

post -book
1. When using TAR compression and decompression system compression packs, always report an error
TAR: Due to the previous error, the wrong state of the above error is exited
At first using -v parameters to print a lot of log information in the console, so I later used the>/dev/null to block the standard output and only printed the standard error output. I originally thought it was because of some file permissions (although I used ROOT User), but after the shielding standard is output, the reason for the error is still unable to locate. The error log is still, and the compressed file is also available. The system is consistent with the source system. So it is not yet deliberate, and then take a closer look at it.
2. In the tar instruction parameter, I put the -P after -F, but the use of this will directly report an error and cannot continue. The -F parameter is -F <mart file> or –file = <Library file>:: Specify the backup file; -P is to keep the original file attribute (without changes with the user), and it is temporarily understood as a grammar agreement.


Related Posts

Android uses bottomnavigationView to achieve the bottom navigation bar Upgrade to one of the errors of UtilSession failed: Patch 9413827

Custom View Note (3) — ViewDraghelper

mount and umount commands (mounting and uninstalling file system) Deepwater

Four, Spring Security certification and authorization-dynamic authorization solution Still

Random Posts

CC2650DK development based on TI-RTOS (10) — free cycle

containerization | deploy mysql cluster in Rancher

webView and JS interact all methods and use

MATLAB operator

Android-multi-thread download arthur02