感谢田佬的若干帮助,while (true) putchar(‘%‘);
docker pull centos:6
docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
centos 6 d0957ffdf8a2 2 years ago 194MB
docker run -it centos:6
[root@7fee4585addb /]#
[root@7fee4585addb /]# hostname
7fee4585addb
[root@7fee4585addb /]# cat /sys/class/net/eth0/address
02:42:ac:11:00:02
[root@682672e6af90 /]# hostname
682672e6af90
[root@682672e6af90 /]# cat /sys/class/net/eth0/address
02:42:ac:11:00:03
--hostname
和--mac-address
选项指定,下面的命令可以指定hostname为Tadokoro
,mac地址为02:42:AC:11:45:14
docker run -it --hostname Tadokoro --mac-address 02:42:AC:11:45:14 centos:6
[root@Tadokoro /]# hostname
Tadokoro
[root@Tadokoro /]# cat /sys/class/net/eth0/address
02:42:ac:11:45:14
docker run -it --hostname WrongMac --mac-address 11:22:33:44:55:66 centos:6
docker: Error response from daemon:
OCI runtime create failed: container_linux.go:380:
starting container process caused: process_linux.go:545:
container init caused: Running hook #0:: error running hook:
exit status 1, stdout: , stderr: time="2021-08-05T23:09:08+08:00" level=fatal
msg="failed to add interface vethf040ecb to sandbox: error setting interface \"vethf040ecb\" MAC to \"11:22:33:44:55:66\": cannot assign requested address": unknown.
ERRO[0000] error waiting for container: context canceled
yum update
[root@Tadokoro /]# yum update
Loaded plugins: fastestmirror, ovl
Setting up Update Process
YumRepo Error: All mirror URLs are not using ftp, http[s] or file.
Eg. Invalid release/repo/arch combination/
removing mirrorlist with no valid mirrors: /var/cache/yum/x86_64/6/base/mirrorlist.txt
Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify its path and try again
https://www.xmpan.com/Centos-6-Vault-Aliyun.repo
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[base]
name=CentOS-6.10 - Base - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/6.10/os/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-vault/RPM-GPG-KEY-CentOS-6
#released updates
[updates]
name=CentOS-6.10 - Updates - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/6.10/updates/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-vault/RPM-GPG-KEY-CentOS-6
#additional packages that may be useful
[extras]
name=CentOS-6.10 - Extras - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/6.10/extras/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-vault/RPM-GPG-KEY-CentOS-6
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-6.10 - Plus - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/6.10/centosplus/$basearch/
gpgcheck=1
enabled=0
gpgkey=http://mirrors.aliyun.com/centos-vault/RPM-GPG-KEY-CentOS-6
#contrib - packages by Centos Users
[contrib]
name=CentOS-6.10 - Contrib - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/6.10/contrib/$basearch/
gpgcheck=1
enabled=0
gpgkey=http://mirrors.aliyun.com/centos-vault/RPM-GPG-KEY-CentOS-6
etc/yum.repos.d/CentOS-Base.repo
,下面是若干方法
echo > CentOS-Base.repo
echo "# CentOS-Base.repo" >> CentOS-Base.repo
echo "#" >> CentOS-Base.repo
echo "# The mirror system uses the connecting IP address of the client and the" >> CentOS-Base.repo
......
echo > CentOS-Base.repo
vi CentOS-Base.repo
docker cp CentOS-Base.repo [容器ID]:/etc/yum.repos.d/
curl https://www.xmpan.com/Centos-6-Vault-Aliyun.repo > CentOS-Base.repo
yum update
,结果正确Loaded plugins: fastestmirror, ovl
Setting up Update Process
Determining fastest mirrors
base | 3.7 kB 00:00
base/primary_db | 4.7 MB 00:00
extras | 3.4 kB 00:00
extras/primary_db | 29 kB 00:00
updates | 3.4 kB 00:00
updates/primary_db | 12 MB 00:01
Resolving Dependencies
--> Running transaction check
---> Package bind-libs.x86_64 32:9.8.2-0.68.rc1.el6_10.1 will be updated
---> Package bind-libs.x86_64 32:9.8.2-0.68.rc1.el6_10.8 will be an update
---> Package bind-utils.x86_64 32:9.8.2-0.68.rc1.el6_10.1 will be updated
---> Package bind-utils.x86_64 32:9.8.2-0.68.rc1.el6_10.8 will be an update
---> Package binutils.x86_64 0:2.20.51.0.2-5.48.el6 will be updated
---> Package binutils.x86_64 0:2.20.51.0.2-5.48.el6_10.1 will be an update
---> Package ca-certificates.noarch 0:2018.2.22-65.1.el6 will be updated
---> Package ca-certificates.noarch 0:2020.2.41-65.1.el6_10 will be an update
---> Package curl.x86_64 0:7.19.7-53.el6_9 will be updated
---> Package curl.x86_64 0:7.19.7-54.el6_10 will be an update
---> Package dbus-libs.x86_64 1:1.2.24-9.el6 will be updated
......
yum install gcc
yum install gcc-c++
yum install redhat-lsb
.
├── scl
│ ├── scl_v2018.06_common.spf
│ ├── scl_v2018.06_linux64.spf
│ └── scl_v2018.06_windows.exe
├── scl_keygen.zip
├── synopsyinstaller
│ ├── checksum_info.txt
│ ├── installer_INSTALL_README.txt
│ ├── snps_container_INSTALL_README.txt
│ ├── snps_container_v1.0_common.spf
│ └── SynopsysInstaller_v5.0.run
├── vcs
│ ├── checksum_info.txt
│ ├── vcs_INSTALL_README.txt
│ ├── vcs_vO-2018.09-SP2_common.spf
│ └── vcs_vO-2018.09-SP2_linux64.spf
└── verdi
├── verdi_vVerdi_O-2018.09-SP2_common.spf
└── verdi_vVerdi_O-2018.09-SP2_linux64.spf
/home/synopsys
,方便起见,将上述文件也置于home下,Docker内文件树如下[root@Tadokoro home]# tree
.
├── scl
│ ├── scl_v2018.06_common.spf
│ └── scl_v2018.06_linux64.spf
├── synopsyinstaller
│ ├── checksum_info.txt
│ ├── installer_INSTALL_README.txt
│ ├── snps_container_INSTALL_README.txt
│ ├── snps_container_v1.0_common.spf
│ └── SynopsysInstaller_v5.0.run
├── synopsys
├── vcs
│ ├── checksum_info.txt
│ ├── vcs_INSTALL_README.txt
│ ├── vcs_vO-2018.09-SP2_common.spf
│ └── vcs_vO-2018.09-SP2_linux64.spf
└── verdi
├── verdi_vVerdi_O-2018.09-SP2_common.spf
└── verdi_vVerdi_O-2018.09-SP2_linux64.spf
5 directories, 13 files
/home/synopsysInstaller
中,为SynopsysInstaller_v5.0.run添加权限[root@Tadokoro home]# cd synopsyinstaller/
[root@Tadokoro synopsyinstaller]# ls
checksum_info.txt installer_INSTALL_README.txt snps_container_INSTALL_README.txt snps_container_v1.0_common.spf SynopsysInstaller_v5.0.run
[root@Tadokoro synopsyinstaller]# chmod 777 SynopsysInstaller_v5.0.run
SynopsysInstaller_v5.0.run
,地址填写/home/synopsys
[root@Tadokoro synopsyinstaller]# ./SynopsysInstaller_v5.0.run
#******************************************************************
#
# Synopsys Installer Self-Extracting Executable
#
# This script extracts and installs Synopsys Installer 5.0 into
# the given directory
#
# For help type:
#
# SynopsysInstaller_v5.0.run -help
#
#******************************************************************
Please specify installation directory [.]: /home/synopsys
Installing Synopsys Installer 5.0 into the directory ‘/home/synopsys‘...
Unpacking: SynopsysInstaller.tgz ...
Unpacking: singularity.tar.gz ...
Installation complete.
/home/synopsys
中,执行installer,发现在root模式下使用-install_as_root
选项也无法正常启动[root@Tadokoro home]# cd synopsys
[root@Tadokoro synopsys]# ls
batch_installer container container_setup.sh doc install_bin installer setup.sh
[root@Tadokoro synopsys]# ./installer
WARNING: The Installer must not be run from a root user account.
Instead, Installer must be run from a regular user account.
Installing tools from a root account is not supported; in
certain cases this may cause a tool to fail to run properly
for some or all users
To run installer as root [not recommended];, please re-invoke
installer with the -install_as_root switch.
[root@Tadokoro synopsys]# ./installer -install_as_root
invalid command name "id"
while executing
"id -un"
(procedure "getUserName" line 5)
invoked from within
"getUserName"
(procedure "SI_CORE::init" line 23)
invoked from within
"SI_CORE::init"
(procedure "SI_CONFIG::init" line 2)
invoked from within
"SI_CONFIG::init"
(procedure "SI_INSTALL::init" line 2)
invoked from within
"SI_INSTALL::init"
(file "/home/synopsys/install_bin/pinstaller.tcl" line 9)
[root@Tadokoro synopsyinstaller]# useradd usr
[root@Tadokoro synopsys]# su usr
[usr@Tadokoro synopsys]$ ls
batch_installer container container_setup.sh doc install_bin installer setup.sh
[usr@Tadokoro synopsys]$ ./installer
Synopsys (R) Installer
Version 5.0.0
Copyright (c) 2005 - 2021 Synopsys, Inc.
This software and the associated documentation are proprietary to Synopsys, Inc.
This software may only be used in accordance with the terms and conditions of a
written license agreement with Synopsys, Inc. All other use, reproduction, or
distribution of this software is strictly prohibited.
Enter the path to the source directory containing the downloaded EFT file(s) [/home/synopsys]: /home/scl
Enter the full path to the directory where you want to
install Synopsys products. If the directory does not exist,
it will be created. [/usr/synopsys]: /home/synopsys
ERROR: Can‘t install product to destination /home/synopsys.
Destination directory is not writable.
use -target <target dir> to specify a different target directory
[usr@Tadokoro synopsys]$ exit
exit
[root@Tadokoro synopsys]# cd ../
[root@Tadokoro home]# chmod 777 synopsys
[root@Tadokoro home]# cd synopsys
[root@Tadokoro synopsys]# su usr
[usr@Tadokoro synopsys]$ ./installer
Synopsys (R) Installer
Version 5.0.0
Copyright (c) 2005 - 2021 Synopsys, Inc.
This software and the associated documentation are proprietary to Synopsys, Inc.
This software may only be used in accordance with the terms and conditions of a
written license agreement with Synopsys, Inc. All other use, reproduction, or
distribution of this software is strictly prohibited.
Enter the path to the source directory containing the downloaded EFT file(s) [/home/synopsys]: /home/scl
Enter the full path to the directory where you want to
install Synopsys products. If the directory does not exist,
it will be created. [/usr/synopsys]: /home/synopsys
Extracting release information from scl_v2018.06_linux64.spf
Extracting release information from scl_v2018.06_linux64.spf successfully
Extracting release information from scl_v2018.06_common.spf
Extracting release information from scl_v2018.06_common.spf successfully
Your site ID number is in the upper-right corner of your Synopsys license
key certificate. If you have trouble locating it, contact your Synopsys
representative.
Site ID number [000]: 27000
#####################################################
############### Installation Summary ################
Product: SCL (Synopsys Common Licensing) (scl)
Release: 2018.06
Platforms: linux64 common
Disk Space: 103 MB
Target Dir: /home/synopsys/scl/2018.06
Licensed Products communicate with Synopsys servers for the purpose of providing software updates,
detecting software piracy and verifying that customers are using Licensed Products in conformity with
the applicable License Key for such Licensed Products. Synopsys will use information gathered in
connection with this process to deliver software updates and pursue software pirates and infringers.
#####################################################
If the information is correct, continue with the installation.
Accept, Install? [yes]: yes
INFO: Prepare for installing 2018.06 release of product scl ...
INFO: Extracting linux64 package from scl_v2018.06_linux64.spf ...
INFO: Extracting common package from scl_v2018.06_common.spf ...
INFO: Verify SHA256 sum for scl.taz ....
INFO: Verify SHA256 sum for linux64/scl.taz ....
INFO: Installing 2018.06 release of product scl to /home/synopsys/scl/2018.06 ....
INFO: Installing common package for 2018.06 release of product scl ...
INFO: Installing linux64 package for 2018.06 release of product scl ...
INFO: Installation for 2018.06 release of product scl has finished successfully.
Synopsys tools require that a supported version of Synopsys Common
Licensing (SCL) be installed and serving the necessary licenses.
For information on how to obtain SCL, or your license key file,
see http://www.synopsys.com/licensing
For any postinstallation setup requirements, see the product-specific
chapters in the Installation Guide at http://www.synopsys.com/install
INFO: See installer log file /home/synopsys/installer.log
[usr@Tadokoro synopsys]$ ./installer
Synopsys (R) Installer
Version 5.0.0
Copyright (c) 2005 - 2021 Synopsys, Inc.
This software and the associated documentation are proprietary to Synopsys, Inc.
This software may only be used in accordance with the terms and conditions of a
written license agreement with Synopsys, Inc. All other use, reproduction, or
distribution of this software is strictly prohibited.
Enter the path to the source directory containing the downloaded EFT file(s) [/home/synopsys]: /home/vcs
Enter the full path to the directory where you want to
install Synopsys products. If the directory does not exist,
it will be created. [/usr/synopsys]: /home/synopsys
Extracting release information from vcs_vO-2018.09-SP2_linux64.spf
Extracting release information from vcs_vO-2018.09-SP2_linux64.spf successfully
Extracting release information from vcs_vO-2018.09-SP2_common.spf
Extracting release information from vcs_vO-2018.09-SP2_common.spf successfully
Your site ID number is in the upper-right corner of your Synopsys license
key certificate. If you have trouble locating it, contact your Synopsys
representative.
Site ID number [000]: 27000
Post installation setup for VCS - The high-performance, high-capacity Verilog? simulator:
To use SmartSearch ,it is mandatory to download the Python package from SolvNet(Documentation --> VG SmartSearch). Enter the full path to the source directory:
If Yes, please enter the full path to the source directory containing the VCS/VCS-MX Docs+SmartSearch tarball:
Enter the full path where you want to install python [default location will be <VCS_HOME>/doc/UserGuide]:
Do you wish to install the Docs+SmartSearch for VCS/VCS-MX ? : [yes]: no
#####################################################
############### Installation Summary ################
Product: VCS - The high-performance, high-capacity Verilog? simulator (vcs)
Release: O-2018.09-SP2
Platforms: linux64 common
Disk Space: 4431 MB
Target Dir: /home/synopsys/vcs/O-2018.09-SP2
Licensed Products communicate with Synopsys servers for the purpose of providing software updates,
detecting software piracy and verifying that customers are using Licensed Products in conformity with
the applicable License Key for such Licensed Products. Synopsys will use information gathered in
connection with this process to deliver software updates and pursue software pirates and infringers.
#####################################################
If the information is correct, continue with the installation.
Accept, Install? [yes]: yes
INFO: Prepare for installing O-2018.09-SP2 release of product vcs ...
INFO: Extracting linux64 package from vcs_vO-2018.09-SP2_linux64.spf ...
INFO: Extracting common package from vcs_vO-2018.09-SP2_common.spf ...
INFO: Verify SHA256 sum for vcs.bz2 ....
INFO: Verify SHA256 sum for linux64/vcs.bz2 ....
INFO: Installing O-2018.09-SP2 release of product vcs to /home/synopsys/vcs/O-2018.09-SP2 ....
INFO: Installing common package for O-2018.09-SP2 release of product vcs ...
INFO: Installing linux64 package for O-2018.09-SP2 release of product vcs ...
INFO: Running post-installation script: /home/synopsys/vcs/O-2018.09-SP2/etc/post_install.sh -r /home/synopsys/vcs/O-2018.09-SP2 -plat "linux64" -pythonVersion "" -docSourcePath "" -pythonDestinationPath "default location will be <VCS_HOME>/doc/UserGuide" -installDoc "no"
INFO: Installation for O-2018.09-SP2 release of product vcs has finished successfully.
Synopsys tools require that a supported version of Synopsys Common
Licensing (SCL) be installed and serving the necessary licenses.
For information on how to obtain SCL, or your license key file,
see http://www.synopsys.com/licensing
For any postinstallation setup requirements, see the product-specific
chapters in the Installation Guide at http://www.synopsys.com/install
INFO: See installer log file /home/synopsys/installer.log
To use SmartSearch ,it is mandatory to download the Python package from SolvNet(Documentation --> VG SmartSearch). Enter the full path to the source directory:
If Yes, please enter the full path to the source directory containing the VCS/VCS-MX Docs+SmartSearch tarball:
Enter the full path where you want to install python [default location will be <VCS_HOME>/doc/UserGuide]:
Do you wish to install the Docs+SmartSearch for VCS/VCS-MX ? : [yes]: no
[usr@Tadokoro synopsys]$ ./installer
Synopsys (R) Installer
Version 5.0.0
Copyright (c) 2005 - 2021 Synopsys, Inc.
This software and the associated documentation are proprietary to Synopsys, Inc.
This software may only be used in accordance with the terms and conditions of a
written license agreement with Synopsys, Inc. All other use, reproduction, or
distribution of this software is strictly prohibited.
Enter the path to the source directory containing the downloaded EFT file(s) [/home/synopsys]: /home/verdo
Enter the full path to the directory where you want to
install Synopsys products. If the directory does not exist,
it will be created. [/usr/synopsys]: ^Z
[1]+ Stopped ./installer
[usr@Tadokoro synopsys]$ ./installer
Synopsys (R) Installer
Version 5.0.0
Copyright (c) 2005 - 2021 Synopsys, Inc.
This software and the associated documentation are proprietary to Synopsys, Inc.
This software may only be used in accordance with the terms and conditions of a
written license agreement with Synopsys, Inc. All other use, reproduction, or
distribution of this software is strictly prohibited.
Enter the path to the source directory containing the downloaded EFT file(s) [/home/synopsys]: /home/verdi
Enter the full path to the directory where you want to
install Synopsys products. If the directory does not exist,
it will be created. [/usr/synopsys]: /home/synopsys
Extracting release information from verdi_vVerdi_O-2018.09-SP2_common.spf
Extracting release information from verdi_vVerdi_O-2018.09-SP2_common.spf successfully
Extracting release information from verdi_vVerdi_O-2018.09-SP2_linux64.spf
Extracting release information from verdi_vVerdi_O-2018.09-SP2_linux64.spf successfully
Your site ID number is in the upper-right corner of your Synopsys license
key certificate. If you have trouble locating it, contact your Synopsys
representative.
Site ID number [000]: 27000
#####################################################
############### Installation Summary ################
Product: VERDI - The Industry‘s Open Debug Platform (verdi)
Release: Verdi_O-2018.09-SP2
Platforms: common linux64
Disk Space: 7535 MB
Target Dir: /home/synopsys/verdi/Verdi_O-2018.09-SP2
Licensed Products communicate with Synopsys servers for the purpose of providing software updates,
detecting software piracy and verifying that customers are using Licensed Products in conformity with
the applicable License Key for such Licensed Products. Synopsys will use information gathered in
connection with this process to deliver software updates and pursue software pirates and infringers.
#####################################################
If the information is correct, continue with the installation.
Accept, Install? [yes]: yes
INFO: Prepare for installing Verdi_O-2018.09-SP2 release of product verdi ...
INFO: Extracting common package from verdi_vVerdi_O-2018.09-SP2_common.spf ...
INFO: Extracting linux64 package from verdi_vVerdi_O-2018.09-SP2_linux64.spf ...
INFO: Verify SHA256 sum for verdi.bz2 ....
INFO: Verify SHA256 sum for linux64/verdi.bz2 ....
INFO: Installing Verdi_O-2018.09-SP2 release of product verdi to /home/synopsys/verdi/Verdi_O-2018.09-SP2 ....
INFO: Installing common package for Verdi_O-2018.09-SP2 release of product verdi ...
INFO: Installing linux64 package for Verdi_O-2018.09-SP2 release of product verdi ...
INFO: Installation for Verdi_O-2018.09-SP2 release of product verdi has finished successfully.
Synopsys tools require that a supported version of Synopsys Common
Licensing (SCL) be installed and serving the necessary licenses.
For information on how to obtain SCL, or your license key file,
see http://www.synopsys.com/licensing
For any postinstallation setup requirements, see the product-specific
chapters in the Installation Guide at http://www.synopsys.com/install
INFO: See installer log file /home/synopsys/installer.log
[usr@Tadokoro synopsys]$ exit
exit
[root@Tadokoro synopsys]# ls
batch_installer container container_setup.sh doc install_bin installer installer.log scl setup.sh vcs verdi
[root@Tadokoro synopsys]# rm installer.log
rm: remove regular file `installer.log‘? y
[root@Tadokoro synopsys]# cd ../
[root@Tadokoro home]# ls
scl synopsyinstaller synopsys usr vcs verdi
[root@Tadokoro home]# rm -rf scl
[root@Tadokoro home]# rm -rf synopsyinstaller/
[root@Tadokoro home]# rm -rf vcs
[root@Tadokoro home]# rm -rf verdi
[root@Tadokoro home]# chmod 755 synopsys/
DAEMON snpslmd
↓
DAEMON snpslmd /home/synopsys/scl/2018.06/linux64/bin/snpslmd
/home/synopsys/vcs/license
和/home/synopsys/verdi/license
[root@Tadokoro license]# ls
Synopsys.dat
[root@Tadokoro license]# pwd
/home/synopsys/vcs/license
[root@Tadokoro license]# ls
Synopsys.dat
[root@Tadokoro license]# pwd
/home/synopsys/verdi/license
/home/synopsys/scl/2018.06/linux64/bin
,执行下面的指令./lmgrd -c /home/synopsys/vcs/license/Synopsys.dat
......
2:59:30 (snpslmd) SLOG: Statistics Log Frequency is 240 minute(s).
2:59:30 (snpslmd) SLOG: TS update poll interval is 0. TS update is detected by midnight reread only.
2:59:30 (snpslmd) SLOG: Activation borrow reclaim percentage is 0.
2:59:30 (snpslmd) (@snpslmd-SLOG@) ===============================================
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Vendor Daemon ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Vendor daemon: snpslmd
2:59:30 (snpslmd) (@snpslmd-SLOG@) Start-Date: Fri Aug 06 2021 02:59:30 UTC
2:59:30 (snpslmd) (@snpslmd-SLOG@) PID: 83
2:59:30 (snpslmd) (@snpslmd-SLOG@) VD Version: v11.14.1.3 build 212549 x64_lsb ( build 212549 (ipv6))
2:59:30 (snpslmd) (@snpslmd-SLOG@)
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Startup/Restart Info ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Options file used: None
2:59:30 (snpslmd) (@snpslmd-SLOG@) Is vendor daemon a CVD: Yes
2:59:30 (snpslmd) (@snpslmd-SLOG@) Is TS accessed: No
2:59:30 (snpslmd) (@snpslmd-SLOG@) TS accessed for feature load: -NA-
2:59:30 (snpslmd) (@snpslmd-SLOG@) Number of VD restarts since LS startup: 0
2:59:30 (snpslmd) (@snpslmd-SLOG@)
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Network Info ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Listening port: 35911
2:59:30 (snpslmd) (@snpslmd-SLOG@) Daemon select timeout (in seconds): 1
2:59:30 (snpslmd) (@snpslmd-SLOG@)
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Host Info ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Host used in license file: Tadokoro
2:59:30 (snpslmd) (@snpslmd-SLOG@) Running on Hypervisor: Not determined - treat as Physical
2:59:30 (snpslmd) (@snpslmd-SLOG@) ===============================================
......
2:44:03 (snpslmd) Feature sparallel superseded by sparallel
2:44:03 (snpslmd) Cannot open daemon lock file
2:44:03 (snpslmd) EXITING DUE TO SIGNAL 41 Exit reason 9
2:44:03 (lmgrd) snpslmd exited with status 41 (Exited because another server was running)
2:44:03 (lmgrd) MULTIPLE "snpslmd" license server systems running.
2:44:03 (lmgrd) Please kill, and run lmreread
2:44:03 (lmgrd)
2:44:03 (lmgrd) This error probably results from either:
2:44:03 (lmgrd) 1. Another copy of the license server manager (lmgrd) is running.
2:44:03 (lmgrd) 2. A prior license server manager (lmgrd) was killed with "kill -9"
2:44:03 (lmgrd) (which would leave the vendor daemon running).
2:44:03 (lmgrd) To correct this, do a "ps -ax | grep snpslmd"
2:44:03 (lmgrd) (or equivalent "ps" command)
2:44:03 (lmgrd) and kill the "snpslmd" process.
2:44:03 (lmgrd)
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <dirent.h>
#include <dlfcn.h>
#include <string.h>
static int is_root = 0;
static int d_ino = -1;
static DIR *(*orig_opendir)(const char *name);
static int (*orig_closedir)(DIR *dirp);
static struct dirent *(*orig_readdir)(DIR *dirp);
DIR *opendir(const char *name)
{
if (strcmp(name, "/") == 0)
is_root = 1;
return orig_opendir(name);
}
int closedir(DIR *dirp)
{
is_root = 0;
return orig_closedir(dirp);
}
struct dirent *readdir(DIR *dirp)
{
struct dirent *r = orig_readdir(dirp);
if (is_root && r)
{
if (strcmp(r->d_name, ".") == 0)
r->d_ino = d_ino;
else if (strcmp(r->d_name, "..") == 0)
r->d_ino = d_ino;
}
return r;
}
static __attribute__((constructor)) void init_methods()
{
orig_opendir = dlsym(RTLD_NEXT, "opendir");
orig_closedir = dlsym(RTLD_NEXT, "closedir");
orig_readdir = dlsym(RTLD_NEXT, "readdir");
DIR *d = orig_opendir("/");
struct dirent *e = orig_readdir(d);
while (e)
{
if (strcmp(e->d_name, ".") == 0)
{
d_ino = e->d_ino;
break;
}
e = orig_readdir(d);
}
orig_closedir(d);
if (d_ino == -1)
{
puts("Failed to determine root directory inode number");
exit(EXIT_FAILURE);
}
}
[root@Tadokoro bin]# gcc -ldl -shared -fPIC gen-snpslmd-hack.c -o snpslmd-hack.so
[root@Tadokoro bin]# ls
config.xml install_fnp.sh lmgrd lmstat README.TXT server_debug_conf.xml ssdm_admin sssverify watchlog.conf
FNPLicensingService lmdiag lmhostid lmutil sclsh snpslmd ssdm_collect sssverify-trl whatscl
gen-snpslmd-hack.c lmdown lmreread lmver sclsort snpslmd-hack.so sshostid watchlog
[root@Tadokoro bin]# pwd
/home/synopsys/scl/2018.06/linux64/bin
[root@Tadokoro bin]# ps -a
PID TTY TIME CMD
65 pts/1 00:00:00 lmgrd
78 pts/1 00:00:00 ps
[root@Tadokoro bin]# ./lmdown
lmdown - Copyright (c) 1989-2017 Flexera Software LLC. All Rights Reserved.
Port@Host Vendors
1) 27000@Tadokoro snpslmd
Are you sure (y/n)? y
2:57:07 (lmgrd) SHUTDOWN request from root at node Tadokoro
2:57:07 (lmgrd) lmgrd will now shut down all the vendor daemons
2:57:07 (lmgrd) EXITING DUE TO SIGNAL 15
1 FlexNet License Server shut down
[root@Tadokoro bin]# ps -a
PID TTY TIME CMD
80 pts/1 00:00:00 ps
LD_PRELOAD=./snpslmd-hack.so ./lmgrd -c /home/synopsys/vcs/license/Synopsys.dat
......
2:59:30 (snpslmd) SLOG: Statistics Log Frequency is 240 minute(s).
2:59:30 (snpslmd) SLOG: TS update poll interval is 0. TS update is detected by midnight reread only.
2:59:30 (snpslmd) SLOG: Activation borrow reclaim percentage is 0.
2:59:30 (snpslmd) (@snpslmd-SLOG@) ===============================================
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Vendor Daemon ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Vendor daemon: snpslmd
2:59:30 (snpslmd) (@snpslmd-SLOG@) Start-Date: Fri Aug 06 2021 02:59:30 UTC
2:59:30 (snpslmd) (@snpslmd-SLOG@) PID: 83
2:59:30 (snpslmd) (@snpslmd-SLOG@) VD Version: v11.14.1.3 build 212549 x64_lsb ( build 212549 (ipv6))
2:59:30 (snpslmd) (@snpslmd-SLOG@)
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Startup/Restart Info ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Options file used: None
2:59:30 (snpslmd) (@snpslmd-SLOG@) Is vendor daemon a CVD: Yes
2:59:30 (snpslmd) (@snpslmd-SLOG@) Is TS accessed: No
2:59:30 (snpslmd) (@snpslmd-SLOG@) TS accessed for feature load: -NA-
2:59:30 (snpslmd) (@snpslmd-SLOG@) Number of VD restarts since LS startup: 0
2:59:30 (snpslmd) (@snpslmd-SLOG@)
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Network Info ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Listening port: 35911
2:59:30 (snpslmd) (@snpslmd-SLOG@) Daemon select timeout (in seconds): 1
2:59:30 (snpslmd) (@snpslmd-SLOG@)
2:59:30 (snpslmd) (@snpslmd-SLOG@) === Host Info ===
2:59:30 (snpslmd) (@snpslmd-SLOG@) Host used in license file: Tadokoro
2:59:30 (snpslmd) (@snpslmd-SLOG@) Running on Hypervisor: Not determined - treat as Physical
2:59:30 (snpslmd) (@snpslmd-SLOG@) ===============================================
/root/.bashrc
文件中即可,如采用了不同的安装路径,则需修改下文中的路径,如采用了不同的hostname,则需修改下文中的LM_LICENSE_FILE#SCL
export PATH=$PATH:/home/synopsys/scl/2018.06/linux64/bin
export VCS_ARCH_OVERRIDE=linux
#DVE
export PATH=$PATH:/home/synopsys/vcs/O-2018.09-SP2/gui/dve/bin
alias dve=‘dve -full64‘
#VCS
export PATH=$PATH:/home/synopsys/vcs/O-2018.09-SP2/bin
alias vcs=‘vcs -full64 -cpp g++ -cc gcc -LDFLAGS -Wl,--no-as-needed‘
#VERDI
export PATH=$PATH:/home/synopsys/verdi/Verdi_O-2018.09-SP2/bin
export VCS_HOME=/home/synopsys/vcs/O-2018.09-SP2
export VERDI_HOME=/home/synopsys/verdi/Verdi_O-2018.09-SP2
export NOVAS_HOME=/home/synopsys/verdi/Verdi_O-2018.09-SP2
alias verdi=‘verdi‘
#LICENCE
export LM_LICENSE_FILE=27000@Tadokoro
export LD_PRELOAD=‘/home/synopsys/scl/2018.06/linux64/bin/snpslmd-hack.so‘
alias lmg_vcs=‘/home/synopsys/scl/2018.06/linux64/bin/lmgrd -c /home/synopsys/vcs/license/Synopsys.dat‘
source /root/.bashrc
[root@Tadokoro /]# lmg_vcs
3:10:27 (lmgrd) -----------------------------------------------
3:10:27 (lmgrd) Please Note:
3:10:27 (lmgrd)
3:10:27 (lmgrd) This log is intended for debug purposes only.
3:10:27 (lmgrd) In order to capture accurate license
3:10:27 (lmgrd) usage data into an organized repository,
3:10:27 (lmgrd) please enable report logging. Use Flexera Software LLC‘s
......
```=
module tb();
initial begin
$display("hello world");
$finish;
end
endmodule
[root@Tadokoro test]# ls
tb.v
[root@Tadokoro test]# pwd
/home/test
vcs tb.v -full64 -cpp g++ -cc gcc +lint=TFIPC-L -override_timescale=1ns/1ps
......
rm -f _csrc*.so pre_vcsobj_*.so share_vcsobj_*.so
if [ -x ../simv ]; then chmod -x ../simv; fi
g++ -o ../simv -Wl,-rpath-link=./ -Wl,-rpath=‘$ORIGIN‘/simv.daidir/ -Wl,-rpath=./simv.daidir/ -Wl,-rpath=‘$ORIGIN‘/simv.daidir//scsim.db.dir -Wl,--no-as-needed -rdynamic -Wl,-rpath=/home/synopsys/vcs/O-2018.09-SP2/linux64/lib -L/home/synopsys/vcs/O-2018.09-SP2/linux64/lib objs/amcQw_d.o _485_archive_1.so SIM_l.o rmapats_mop.o rmapats.o rmar.o rmar_nd.o rmar_llvm_0_1.o rmar_llvm_0_0.o -lzerosoft_rt_stubs -lvirsim -lerrorinf -lsnpsmalloc -lvfs -lvcsnew -lsimprofile -luclinative /home/synopsys/vcs/O-2018.09-SP2/linux64/lib/vcs_tls.o -Wl,-whole-archive -lvcsucli -Wl,-no-whole-archive /home/synopsys/vcs/O-2018.09-SP2/linux64/lib/vcs_save_restore_new.o -ldl -lc -lm -lpthread -ldl
../simv up to date
CPU time: .206 seconds to compile + .302 seconds to elab + .203 seconds to link
./simv
4:03:57 (snpslmd) OUT: "VCSRuntime_Net" root@Tadokoro [snps_checkout_1628222637]
Chronologic VCS simulator copyright 1991-2018
Contains Synopsys proprietary information.
Compiler version O-2018.09-SP2_Full64; Runtime version O-2018.09-SP2_Full64; Aug 6 04:03 2021
hello world
$finish called from file "tb.v", line 5.
$finish at simulation time 0
V C S S i m u l a t i o n R e p o r t
Time: 0 ps
CPU Time: 0.370 seconds; Data structure size: 0.0Mb
Fri Aug 6 04:03:57 2021
4:03:57 (snpslmd) IN: "VCSRuntime_Net" root@Tadokoro [snps_checkout_1628222637]
原文:https://www.cnblogs.com/Chenrt/p/15107987.html