mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-06-14 10:20:31 +00:00
Remove trailing spaces in file docs/source/guides/admin-guides/manage_clusters/common/deployment/syncfile/syncfile_synclist_file.rst
This commit is contained in:
@ -12,14 +12,14 @@ The synclist file contains the configuration entries that specify where the file
|
||||
The basic entry format looks like following: ::
|
||||
|
||||
path_of_src_file1 -> path_of_dst_file1
|
||||
path_of_src_file1 -> path_of_dst_directory
|
||||
path_of_src_file1 -> path_of_dst_directory
|
||||
path_of_src_file1 path_of_src_file2 ... -> path_of_dst_directory
|
||||
|
||||
The path_of_src_file* should be the full path of the source file on the Management Node.
|
||||
|
||||
The path_of_dst_file* should be the full path of the destination file on target node. Please make sure path_of_dst_file* is not a existing directory on target node, otherwise, the file sync with ``updatenode -r /usr/bin/scp`` or ``xdcp -r /usr/bin/scp`` will fail.
|
||||
|
||||
The path_of_dst_directory should be the full path of the destination directory. Please make sure *eth_of_dst_directory is not a existing file on target node, otherwise, the file sync with ``updatenode -r /usr/bin/scp`` or ``xdcp -r /usr/bin/scp`` will fail.
|
||||
The path_of_dst_directory should be the full path of the destination directory. Please make sure *eth_of_dst_directory is not a existing file on target node, otherwise, the file sync with ``updatenode -r /usr/bin/scp`` or ``xdcp -r /usr/bin/scp`` will fail.
|
||||
|
||||
Since the synclist file is for common purpose, the target node need not be configured in it.
|
||||
|
||||
@ -30,19 +30,19 @@ sync file **/etc/file2** to the file **/etc/file2** on the node (with same file
|
||||
/etc/file2 -> /etc/file2
|
||||
|
||||
sync file **/etc/file2** to the file **/etc/file3** on the node (with different file name) ::
|
||||
|
||||
/etc/file2 -> /etc/file3
|
||||
|
||||
/etc/file2 -> /etc/file3
|
||||
|
||||
sync file **/etc/file4** to the file **/etc/tmp/file5** on the node( different file name and directory). The directory will be automatically created for you. ::
|
||||
|
||||
/etc/file4 -> /etc/tmp/file5
|
||||
|
||||
sync the multiple files **/etc/file1**, **/etc/file2**, **/etc/file3**, ... to the directory **/tmp/etc** (**/tmp/etc** must be a directory when multiple files are synced at one time). If the directory does not exist,**xdcp** will create it. ::
|
||||
|
||||
|
||||
/etc/file1 /etc/file2 /etc/file3 -> /tmp/etc
|
||||
|
||||
sync file **/etc/file2** to the file /etc/file2 on the node ::
|
||||
|
||||
|
||||
/etc/file2 -> /etc/
|
||||
|
||||
sync all files in **/home/mikev** to directory **/home/mikev** on the node ::
|
||||
@ -54,34 +54,34 @@ Note: Don't try to sync files to the read only directory on the target node.
|
||||
An example of synclist file
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Assume a user wants to sync files to a node as following, the corresponding entries should be added in a synclist file.
|
||||
Assume a user wants to sync files to a node as following, the corresponding entries should be added in a synclist file.
|
||||
|
||||
Sync the file **/etc/common_hosts** to the two places on the target node: put one to the **/etc/hosts**, the other to the **/tmp/etc/hosts**. Following configuration entries should be added ::
|
||||
|
||||
/etc/common_hosts -> /etc/hosts
|
||||
/etc/common_hosts -> /tmp/etc/hosts
|
||||
|
||||
/etc/common_hosts -> /tmp/etc/hosts
|
||||
|
||||
Sync files in the directory **/tmp/prog1** to the directory **/prog1** on the target node, and the postfix **'.tmpl'** needs to be removed on the target node. (directory **/tmp/prog1/** contains two files: **conf1.tmpl** and **conf2.tmpl**) Following configuration entries should be added ::
|
||||
|
||||
/tmp/prog1/conf1.tmpl -> /prog1/conf1
|
||||
/tmp/prog1/conf2.tmpl -> /prog1/conf2
|
||||
|
||||
Sync the files in the directory **/tmp/prog2** to the directory **/prog2** with same name on the target node. (directory **/tmp/prog2** contains two files: **conf1** and **conf2**) Following configuration entries should be added: ::
|
||||
|
||||
|
||||
/tmp/prog2/conf1 /tmp/prog2/conf2 -> /prog2
|
||||
|
||||
Sample synclist file ::
|
||||
|
||||
|
||||
/etc/common_hosts -> /etc/hosts
|
||||
/etc/common_hosts -> /tmp/etc/hosts
|
||||
/tmp/prog1/conf1.tmpl -> /prog1/conf1
|
||||
/tmp/prog1/conf2.tmpl -> /prog1/conf2
|
||||
/tmp/prog2/conf1 /tmp/prog2/conf2 -> /prog2
|
||||
/tmp/* -> /tmp/
|
||||
/etc/testfile -> /etc/
|
||||
/tmp/* -> /tmp/
|
||||
/etc/testfile -> /etc/
|
||||
|
||||
If the above syncfile is performed by the **updatenode/xdcp** commands, or performed in a node installation process, the following files will exist on the target node with the following contents. ::
|
||||
|
||||
|
||||
/etc/hosts(It has the same content with /etc/common_hosts on the MN)
|
||||
/tmp/etc/hosts(It has the same content with /etc/common_hosts on the MN)
|
||||
/prog1/conf1(It has the same content with /tmp/prog1/conf1.tmpl on the MN)
|
||||
@ -109,12 +109,12 @@ The noderange would have several format. Following examples show that /etc/hosts
|
||||
postscript support
|
||||
~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Putting the filename.post in the **rsyncfile** to ``rsync`` to the node is required for hierarchical clusters. It is optional for non-hierarchical cluster.
|
||||
Putting the filename.post in the **rsyncfile** to ``rsync`` to the node is required for hierarchical clusters. It is optional for non-hierarchical cluster.
|
||||
|
||||
Advanced synclist file features
|
||||
Advanced synclist file features
|
||||
''''''''''''''''''''''''''''''''''
|
||||
|
||||
After you define the files to rsync in the syncfile, you can add an **EXECUTEALWAYS** clause in the syncfile. The **EXECUTEALWAYS** clause will list all the postscripts you would always like to run after the files are sync'd, whether or not any file is actually updated. The files in this list must be added to the list of files to rsync, if hierarchical.
|
||||
After you define the files to rsync in the syncfile, you can add an **EXECUTEALWAYS** clause in the syncfile. The **EXECUTEALWAYS** clause will list all the postscripts you would always like to run after the files are sync'd, whether or not any file is actually updated. The files in this list must be added to the list of files to rsync, if hierarchical.
|
||||
|
||||
For example, your rsyncfile may look like this. **Note: the path to the file to EXECUTE, is the location of the *.post file on the MN**. ::
|
||||
|
||||
@ -129,15 +129,15 @@ For example, your rsyncfile may look like this. **Note: the path to the file to
|
||||
EXECUTE:
|
||||
/tmp/share/file2.post
|
||||
/tmp/share/file3.post
|
||||
EXECUTEALWAYS:
|
||||
EXECUTEALWAYS:
|
||||
/tmp/myscript1
|
||||
/tmp/myscript2
|
||||
/tmp/myscript2
|
||||
|
||||
If **/tmp/file2** is updated on the node in **/tmp/file2**, then **/tmp/file2**.post is automatically run on that node. If **/tmp/file3** is updated on the node in **/tmp/filex**, then **/tmp/file3**.post is automatically run on that node.
|
||||
|
||||
You can add an **APPEND** clause to your syncfile.
|
||||
|
||||
The **APPEND** clause is used to append the contents of the input file to an existing file on the node. The file to be appended must already exist on the node and not be part of the synclist that contains the **APPEND** clause.
|
||||
The **APPEND** clause is used to append the contents of the input file to an existing file on the node. The file to be appended must already exist on the node and not be part of the synclist that contains the **APPEND** clause.
|
||||
|
||||
For example, your synclist file may look like this: ::
|
||||
|
||||
@ -164,7 +164,7 @@ Note:no order of execution may be assumed by the order that the **EXECUTE,EXECUT
|
||||
|
||||
You can add an **MERGE** clause to your syncfile. This is only supported on Linux.
|
||||
|
||||
The **MERGE** clause is used to append the contents of the input file to either the **/etc/passwd**, **/etc/shadow** or **/etc/group** files. They are the only supported files. You must not put the **/etc/passwd**, **/etc/shadow**, **/etc/group** files in an **APPEND** clause if using a **MERGE** clause. For these three file you should use a **MERGE** clause. The **APPEND** will add the information to the end of the file. The **MERGE** will add or replace the information and insure that there are no duplicate entries in these files.
|
||||
The **MERGE** clause is used to append the contents of the input file to either the **/etc/passwd**, **/etc/shadow** or **/etc/group** files. They are the only supported files. You must not put the **/etc/passwd**, **/etc/shadow**, **/etc/group** files in an **APPEND** clause if using a **MERGE** clause. For these three file you should use a **MERGE** clause. The **APPEND** will add the information to the end of the file. The **MERGE** will add or replace the information and insure that there are no duplicate entries in these files.
|
||||
|
||||
For example, your synclist file may look like this ::
|
||||
|
||||
@ -184,16 +184,16 @@ For example, your synclist file may look like this ::
|
||||
/etc/mydir/mergeshadow -> /etc/shadow
|
||||
/etc/mydir/mergegroup -> /etc/group
|
||||
|
||||
When you use the **MERGE** clause, the file (left) of the arrow is merged into the file right of the arrow. It will replace any common userid's found in those files and add new userids. The /opt/xcat/share/xcat/scripts/xdcpmerge.sh is used to accomplish this.
|
||||
When you use the **MERGE** clause, the file (left) of the arrow is merged into the file right of the arrow. It will replace any common userid's found in those files and add new userids. The /opt/xcat/share/xcat/scripts/xdcpmerge.sh is used to accomplish this.
|
||||
|
||||
Note: no order of execution may be assumed by the order that the **EXECUTE,EXECUTEALWAYS,APPEND and MERGE** clause fall in the synclist file.
|
||||
Note: no order of execution may be assumed by the order that the **EXECUTE,EXECUTEALWAYS,APPEND and MERGE** clause fall in the synclist file.
|
||||
|
||||
.. _the_localtion_of_synclist_file_for_updatenode_label:
|
||||
|
||||
The location of synclist file for updatenode and install process
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
In the installation process or updatenode process, xCAT needs to figure out the location of the synclist file automatically, so the synclist should be put into the specified place with the proper name.
|
||||
In the installation process or updatenode process, xCAT needs to figure out the location of the synclist file automatically, so the synclist should be put into the specified place with the proper name.
|
||||
|
||||
If the provisioning method for the node is an osimage name, then the path to the synclist will be read from the osimage definition synclists attribute. You can display this information by running the following command, supplying your osimage name. ::
|
||||
|
||||
@ -212,7 +212,7 @@ If the provisioning method for the node is an osimage name, then the path to the
|
||||
rootimgdir=/install/netboot/<os>/<arch>/compute
|
||||
**synclists=/install/custom/netboot/compute.synclist**
|
||||
|
||||
You can set the synclist path using the following command ::
|
||||
You can set the synclist path using the following command ::
|
||||
|
||||
chdef -t osimage -o <os>-<arch>-netboot-compute synclists="/install/custom/netboot/compute.synclist
|
||||
|
||||
|
Reference in New Issue
Block a user