2020年8月3日 星期一

How to make Ubuntu support "exFAT" file system

How to make Ubuntu support "exFAT" file system

When meet "mount:unknown filesystem sype 'exfat'"

$sudo apt-get install exfat-utils exfat-fuse

2020年6月17日 星期三

2020年6月12日 星期五

How to mount a windows/samba windows share under Linux

How to mount a windows/samba windows share under Linux

You have windows to open share folder, and you want your linux client can access this folder.

From linux client
#mount -t cifs -o "username=XXX,password=XXX" //[windows_IP]/[Windows_folder] /mnt

2020年6月8日 星期一

2020年6月3日 星期三

How to change Centos 7 run level graphic<=>text

How to change Centos 7 run level graphic<=>text


1. Check current run level
#systemctl get-default


2. Change run level from graphic to text
#systemctl set-default multi-user.target
#init 6


3. Change run level from text to graphic
#systemctl set-default graphical.target
#init 6



---------------------------------------
[Centos 6]

1.Change run level from graphic to text
#vim  /etc/inittab
id:3:initdefault:

2. Change run level from text to graphic
#vim  /etc/inittab
id:5:initdefault:




2020年5月14日 星期四

How to check hardware information (CPU/MEM/Disk/PCIE card) by command under linux

How to check hardware information (CPU/MEM/Disk/PCIE card) by command under linux


How many physical cpu install
# cat /proc/cpuinfo| grep "physical id"| sort| uniq| wc -l
2

Cpu core number 
# cat /proc/cpuinfo| grep "cpu cores"| uniq
cpu cores : 2
# cat /proc/cpuinfo| grep "cpu cores"| uniq | awk {'print $4'}
2

Total CPU logical core
# cat /proc/cpuinfo| grep "processor"| wc -l
4

CPU model
#cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c
      4  Intel(R) Xeon(R) Platinum 8170 CPU @ 2.10GHz

# cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c |  awk {'print $5'}
8170

CPU code name

#cat /sys/devices/cpu/caps/pmu_name
Skylake , Haswell

CPU TDP (Need PTU linux tool)
./ptumon -s | grep -i "package tdp" | awk {'print$4'}

CPU turbo frequency
#dmidecode | grep -I "max speed" | tr -d "\n" | awk {'print$3'}


memory brand:
#dmidecode -t memory | grep -i manufacturer | tr -d "\n" | awk {'print$2'}


memory model
#dmidecode -t memory | grep -i part | tr -d "\n" | awk {'print$3'}

memory single size 
#dmidecode -t memory | grep -i size | tr -d "\n" | awk {'print$2'}

memory speed
#dmidecode -t memory | grep -i speed | tr -d "\n" | awk {'print$2'}


memory type & speed
# lshw | grep -i *-bank:0 -A 2 | sed '2!d' | awk {'print$3"-"$5'}

DDR4-2666

memory total size
#lshw -class memory | grep -i "system memory" -A 5 | sed '4!d' | awk {'print$2'}

memory slots
#midecode -t memory | grep -i part | wc -l 

Disk model

#lsblk --nodeps -o model | sed '2!d'  

Detail disk information
#smart -a /dev/yourdrive

Disk IO performance

#iostat -m

PCIE card 
# lspci | grep -i ethernet ; lspci | grep -i raid ; lspci | grep -i vga 
 

2020年5月12日 星期二

Sysbench

Sysbench

Setup :
#yum -y remove mariadb-libs

#yum install mysql-community-server -y
#yum install mysql-community-devel.x86_64
#service mysqld restart
#cd sysbench-0.4.12.14
#./autogen.sh
#./configure --with-mysql
#make 
#make install
-------------------------------------------------------------------------------
Running:

CPU benchmark
#sysbench --test=cpu --cpu-max-prime=20000 --max-time=120 run


Memory benchmark
#sysbench --test=memory  --max-time=120 run

IO benchmark
#sysbench --test=fileio --file-total-size=1G --file-test-mode=rndrw prepare

#sysbench --test=fileio --file-total-size=1G --file-test-mode=rndrw run

Clean the test file
#sysbench --test=fileio --file-total-size=1G --file-test-mode=rndrw cleanup

MySQL benchmark
#vim /etc/my.cnf
add new line under [mysqld] 
skip-grant-tables
# service mysqld restart
#mysql -u root -p
Input Aa123456
mysql>create database sbtest;

Execute in another terminal
#sysbench --test=oltp --db-driver=mysql --oltp-table-size=10000 --mysql-db=sbtest --mysql-user=root --mysql-password=Aa123456 prepare
#sysbench --test=oltp --db-driver=mysql --oltp-table-size=10000 --mysql-db=sbtest --mysql-user=root --mysql-password=Aa123456 run

Clean the test file
#sysbench --test=oltp --db-driver=mysql --oltp-table-size=10000 --mysql-db=sbtest --mysql-user=root --mysql-password=Aa123456 cleanup

Unixbench

Unixbench

https://code.google.com/archive/p/byte-unixbench/downloads 
(download 5.1.3 version)


#tar zxvf unixbench-5.1.3.tar.gz
#cd unixbench-5.1.3
#make
#./Run

It will run about 1 hour.

GPU burn

GPU burn


Install driver
Install cuda


Check all well by listing your GPUs (Command 1 below) and checking the properties of GPUs ( Command 2 below) , and checking nvcc is setup (Command 3 below). If you don’t get a meaningful response, most likely something is off with your environment variables or worst case your driver / CUDA version
  1. nvidia-smi
  2. nvidia-smi -q
  3. nvcc -V

Download gpu burn from 

#unzip gpu-burn-master.zip
#cd gpu-burn-master
#make


Running GPU Burn (Few example commands below)
  1.  ./gpu_burn  (Single precision GPU burn for 10 seconds)
  2. ./gpu_burn -d ( Double precision GPU burn for 10 seconds)
  3. ./gpu_burn 120 (Single precision GPU burn for 120 seconds)

2020年3月16日 星期一

Intel X710 OCP has confusing name device manager


Intel X710 OCP has confusing name device manager




The OCP have two ports , and it show different name under BIOS.
The windows os device manager also follow the different name.

1st Port: Intel(R) Ethernet Controller X710 for 10GbE SFP+ Other Ports: Intel(R) Ethernet Converged Network Adapter X710



This is known issue.
From Intel document, https://downloadcenter.intel.com/download/22283/Intel-Ethernet-Adapter-Complete-Driver-Pack => Please refer to the "Adapter User Guide.pdf" from the driver package
search "correct branding". in this pdf.


Compatibility Notes
Devices based on the Intel Ethernet Controller XL710 (4x10 GbE, 1x40 GbE, 2x40 GbE) have an expected
total throughput for the entire device of 40 Gb/s in each direction.
The first port of Intel® Ethernet Controller 700 Series based adapters will display the correct branding string.

All other ports on the same device will display a generic branding string.


2020年3月5日 星期四

2020年1月30日 星期四

How to check CPU&memory loading under ubuntu

How to check CPU&memory loading under ubuntu

Memory
#free -m

CPU
#top

Or install sw
#sudo apt-get install htop
#htop

2020年1月29日 星期三

Missing libraries in Ubuntu when running burnin test

Missing libraries in Ubuntu when running burnin test


System have to connect to Internet

#sudo apt-get install libqt5opengl5 libqt5printsupport5 libcurl4

2020年1月14日 星期二

Simple dd command to test HDD read/write performance under linux

Simple dd command to test HDD read/write performance under linux    2021/02/22 update

Read
#dd oflag=direct if=/dev/zero of=/mnt/test bs=512k count=20000

Write
#dd iflag=direct if=/mnt/test of=/dev/null bs=512k count=20000

If you want to test different disk, you can mount /mnt to diffect /dev/sdx
#mkfs -t ext4 /dev/sdb1
#mount /dev/sdb1 /mnt

How to fix /lib64/libc.so.6: version `GLIBC_2.15' not found

How to fix  /lib64/libc.so.6: version `GLIBC_2.15' not found

1.
wget https://ftp.gnu.org/gnu/glibc/glibc-2.15.tar.gz

2.
# tar -zxvf glibc-2.15.tar.gz
# cd glibc-2.15
# mkdir build;
# cd build
# ../configure --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin
# make -j 8
# make install

2020年1月13日 星期一

How to install/uninstall/launch LSI/Avago MSM utility under Linux

How to install/uninstall/launch LSI/Avago MSM utility under Linux

install
#./install.csh -a

launch
# cd /user/local/MegaRAID Storage Manager
#./startupui.sh


Uninstall
# cd /user/local/MegaRAID Storage Manager
#./uninstaller.sh

(TOP)Temp for soulin only

123