Tag Archives: linux

Linux running Makefile, G + + / GCC error: suffix or operations invalid for ‘vbroadcasts’

Compiler Error on Linux systems: suffix or operands invalid for ‘vbroadcastss’ solution Error scenario solution reference

Error: suffix or operands invalid for ‘vbroadcastss’ solution
When running Kaggle-2014-Criteo-Master open source program, I encountered errors when compiling and running GBDT, libffm program and Makefile. The intuition was related to the system running the program. A search led to a solution. The
problem is primarily that GCC or g++ compile-time sets the -march parameter, which is a platform-dependent parameter. You need to modify this parameter value to correspond to the machine.
(program download address: https://github.com/ycjuan/kaggle-2014-criteo)
for this open source programs need to modify: Makefile
[file path]/kaggle-2014-criteo/solvers/ GBDT
[file path]/kaggle-2014-criteo/solvers/libffm-1.13 Makefile
-march =native march=broadwel
then Makefile error disappears.
An error scenario
Specifically report the following mistakes:

[dhy@Master kaggle-2014-criteo-master]$ make
make -C solvers/gbdt
make[1]: Entering directory `/home/dhy/code/kaggle-2014-criteo-master/solvers/gbdt'
g++ -Wall -Wconversion -O2 -fPIC -std=c++0x -march=native -fopenmp -o gbdt src/train.cpp src/common.cpp src/timer.cpp src/gbdt.cpp
make[1]: Leaving directory `/home/dhy/code/kaggle-2014-criteo-master/solvers/gbdt'
ln -sf solvers/gbdt/gbdt
make -C solvers/libffm-1.13
make[1]: Entering directory `/home/dhy/code/kaggle-2014-criteo-master/solvers/libffm-1.13'
g++ -Wall -O3 -std=c++0x -march=native -fopenmp -DUSEOMP -c -o ffm.o ffm.cpp
/tmp/ccuUtD2f.s: Assembler messages:
/tmp/ccuUtD2f.s:3671: Error: suffix or operands invalid for `vbroadcastss'
/tmp/ccuUtD2f.s:3787: Error: suffix or operands invalid for `vbroadcastss'
/tmp/ccuUtD2f.s:3917: Error: suffix or operands invalid for `vbroadcastss'
/tmp/ccuUtD2f.s:4071: Error: suffix or operands invalid for `vbroadcastss'
make[1]: *** [ffm.o] Error 1
make[1]: Leaving directory `/home/dhy/code/kaggle-2014-criteo-master/solvers/libffm-1.13'
make: *** [ffm-train] Error 2

The solution
Modify the Makefile, – march = native for – march = broadwell
this is because the GCC/g + + parameters march on different architecture platform corresponding to different – march Options, refer to: https://gcc.gnu.org/onlinedocs/gcc in the “3.18 Machine – Dependent Options” section. To view the machine’s corresponding -march, run the following command 1 :

$gcc -c -Q -march=native --help=target | grep march

My machine to execute the above command appears:

-march=                     		broadwell

Therefore, in the compile file Makefile, the g++ or GCC parameter is set to -march= broadwell.
different cpus corresponding to march selection can refer to the following table: 2
The

CPU type

march option

AMD Barcelona

– march = Barcelona

AMD Bobcat

– march = btver1

AMD Jaguar – march=btver2
AMD Bulldozer – march=bdver1
AMD Piledriver – march=bdver2
AMD Steamroller – march=bdver3
Intel Westmere – march=westmere
Intel Core Nehalem – march=corei7
Intel Core Sandy Bridge – march=corei7-avx
Intel Core Ivy Bridge – march=core-avx-i
Intel Core Haswell – march=core-avx2
Intel Core Broadwell – march=broadwell
Intel Atom Bonnell – march=bonnell
Intel Atom Silvermont – march=silvermont

reference


The

    https://blog.csdn.net/listener51/article/details/80468021 ↩ ︎ http://blog.sciencenet.cn/blog-365047-1014406.html ↩ ︎

Linux uses open source Yum to report error performing checksums

 
Now open source yum has USTC and 163. Repo file downloaded directly from the Internet, running will report an error, manually modified a bit:
 
Ustc yum is used, and the configuration file is as follows:
[root@web1 yum.repos.d]# cat ustc.repo
 
[base]
Name = CentOS – 5.9 – Base – mirrors.ustc.edu.cn
baseurl=http://mirrors.ustc.edu.cn/centos/5.9/os/$basearch/
gpgcheck=0
enabled=1
 
#released updates
[updates]
Name = CentOS – 5.9 – Updates – mirrors.ustc.edu.cn
baseurl=http://mirrors.ustc.edu.cn/centos/5.9/updates/$basearch/
gpgcheck=0
enabled=1
 
#additional packages thatmay be useful
[extras]
Name = CentOS – 5.9 – Extras – mirrors.ustc.edu.cn
baseurl=http://mirrors.ustc.edu.cn/centos/5.9/extras/$basearch/
gpgcheck=0
enabled=1
 
Once configured, perform YUM Update, Error Performing Checksum
 
[root@web1 yum.repos.d]# yum update
Loaded plugins: katello, product-id,security, subscription-manager
Updating certificate-based repositories.
Unable to read consumer identity
Base | 3.7 kB 00:00
The base/primary_db | 4.4 MB 00:02
http://mirrors.ustc.edu.cn/centos/6.4/os/x86_64/repodata/1e584feac3f3fb76ad4b6fb7e1bc8d44fa124814e9d186dc913ded3c63a216b3-primary.sqlite.bz2: [Errno – 3] Error performingchecksum
Trying other mirror.
The base/primary_db | 4.4 MB 00:02
http://mirrors.ustc.edu.cn/centos/6.4/os/x86_64/repodata/1e584feac3f3fb76ad4b6fb7e1bc8d44fa124814e9d186dc913ded3c63a216b3-primary.sqlite.bz2: [Errno – 3] Error performing checksum
Trying other mirror.
Error: failure:repodata/1e584feac3f3fb76ad4b6fb7e1bc8d44fa124814e9d186dc913ded3c63a216b3-primary.sqlite.bz2from base: [Errno 256] No more mirrors to try.
 
 
Google says that the REPomd.xml file USES SHA256 as the hash algorithm in RHEL 6, and SHA as the hash algorithm by default in RHEL 5.
 
But I’m using yum with 5.9 on Redhat 5.8. This error also occurs.
 
The online solution is to use the new SHA1 to rebuild repo:
# createrepo -s sha1 dave-el5-x86_64
 
 
I did not create it here, but just execute the following command:
# yum clean all
 
 
And then it’s ok. Little knowledge, along with notes.
 
 
 
 
 
 
 
 
 
——————————————————————————————–
Copyright, the article is allowed to reprint, but must indicate the source address in the way of link, otherwise the legal responsibility!
QQ:492913789
Email:[email protected]
Blog: http://www.cndba.cn/dave
Weibo: http://weibo.com/tianlesoftware
Twitter: http://twitter.com/tianlesoftware
Facebook: http://www.facebook.com/tianlesoftware
Linkedin: http://cn.linkedin.com/in/tianlesoftware

Linux execution LS error: LS: cannot open directory.: input / output error solution

Linux executes LS error: LS: cannot open Directory.: Input/output error

error message is as follows
analysis: the above situation is usually caused by hard disk problems resulting in file system damage 4. Analysis: the above situation is usually caused by a hard disk problem file system corruption solution: 1. Try restarting the system if you can. 2. Use FSCK for file system repair, which requires unmounting the disk mount first and then using: fSCk-y /dev/sdb1; When the fix is complete, remount the directory and re-enter the directory to see the problem resolved.

When ifconfig configures the network, “siocsifaddr: no such device” and “eth0: error while getting interface” appear flags:No such dev”

I just learned Linux recently. Refer to the instructional video and try to set the network card parameters using the ifconfig command, which is “ifconfig eth0 192.168.11.2”.

Eth0 :ERROR while getting interface flags:No such device. Screenshot below.



After a lot of searching on the Internet, someone suggested that maybe your network card name is not “eth0” but something else. So I entered a single line of code “ifconfig-a” to check all the network card parameters, only to find that my network card name is not “eth0”, but “eno16777736”. So the real statement to modify the nic parameters should be “ifconfig eno16777736 192.168.11.2”.



After that, I used the secureCRT remote login management tool and used “192.168.11.2” to login the virtual machine remotely!

Docker run failed with the following error in logs, standard_ init_ linux.go:211 : exec user process caused “exec format error“

Standard_init_linux. go:211: exec User Process caused “exEC Format Error”
The paper
This problem is encountered in the secondary DockerUI project on the board, which adopts arm7L architecture. The image is based on the Centos Docker build of X86_64, and then the image is packaged into a tar file by Docker Save, and then the image is extracted from the tar file compressed by Docker Load. The image transfer itself is not a problem, and multiple operations have been performed prior to this.
displays the container exit status when docker runs, and docker logs, the container, will report the above error. The reason is that the arch architecture is different, which will affect the docker build image.

1. Pull the official mirror, still report the same error.
2 search this image in dockerhub, sure enough, found a clue, as shown in the red box in the figure below:

Problem location
1. Problems on baidu generally point to entrypoint in dockerfile. I did not encounter various shell
2 and coding problems, because my project is pure CSS +js+ HTML. Finding the root of the problem on Google is that ARCH is different.
Solution
now that the root cause of the problem has been found, it is easy to handle, just need to rebuild docker build on the current arch Linux.
While e sometimes it feels like solving a case, follow the clues to find the root of the problem and solve it. The process was painful, but the results were pretty good.

Tomcat web compression configuration

Compression of output content is supported for later versions of Tomcat5.0, using gZIP compression format
Modify %TOMCAT_HOME%/conf/server.xml, the first Connector node of the file. The specific node to be modified is as follows:
< The Connector port = “80” protocol = “HTTP/1.1”
ConnectionTimeout = “20000”
The redirectPort = “8443”/& gt;
The modified code is as follows:
< The Connector port = “80” protocol = “HTTP/1.1”
ConnectionTimeout = “20000”
The redirectPort = “8443” URIEncoding = “utf-8”
Compression will = “on” compressionMinSize = “2048”
NoCompressionUserAgents = “gozilla, traviata”
CompressableMimeType = “text/HTML, text/XML, text/javascript,
Text/CSS, text/plain “/ & gt;
The following attributes have been added
1. Compression = “on”
2. CompressionMinSize = “2048” with compressed output content size enabled, which is 2KB by default
3. NoCompressionUserAgents = “gozilla, traviata” browsers to be excluded;
4, compressableMimeType = “text/HTML, text/XML, text/javascript, text/CSS, text/plain” compression type
After the modification, restart Tomcat, and finally check the website.

Vsftpd: 500 oops: vsftpd: refusing to run with writable root inside chroot() error

This error is often encountered when using the user to log in to FTP after we have restricted the user from jumping out of his/her home directory:
 

500 OOPS: vsftpd: refusing to run with writable root inside chroot ()

 
This problem occurs in the latest update due to the following update:
 

- Add stronger checks for the configuration error of running with a writeable root directory inside a chroot(). This may bite people who carelessly turned on chroot_local_user but such is life.

 
Since 2.3.5, VSFTPD has enhanced security checks so that if a user is restricted to his or her home directory, the user’s home directory can no longer have write permissions! If the check finds that write permissions are still available, the error is reported.
To fix this error, remove write permissions from the user’s home directory with the command chmod A-w /home/user, and replace the directory with your own. Or you can add one of the following two items to the VSFTPD profile:
allow_writeable_chroot=YES

When the permission question mark appears in the sshfs mount, or input / output error occurs

View hard disk usage df-h
view hard disk information: fdisk-l
eg:
sudo sshfs-o allow_other-o reconnect-o cache=yes www@ip:/ destination file/local file
or
sudo sshfs -o allow_other -o nonempty -o reconnect -o cache=yes www@ip:/data/wwwroot/default/test /home/www/test/uploads
If there is a permission question mark :
close hanging in eg: sudo umount./inquiry
And open;
View hanging information: cat /etc/mtab
running SSHFS: ps aux | grep SSHFS