Linux2020. 12. 8. 18:49

libsox-fmt-all을 설치하지 않으면 다음과 같이 mp3 파일을 인식하지 못한다.

$ sudo apt-get install sox
$ sudo apt-get install libsox-fmt-all

 

$ play 탐험보고.mp3 
play WARN alsa: can't encode 0-bit Unknown or not applicable 
play FAIL formats: no handler for file extension `mp3' 

[링크 : https://vitux.com/play-mp3-files-using-the-ubuntu-command-line/]

 

여러가지가 있어서 해봤지만 sox가 빠르고, 용량도 적고 한번 재생하고 종료되서 딱임

[링크 : https://linuxhint.com/play_mp3_files_commandline/]

[링크 : https://superuser.com/questions/276596/play-mp3-or-wav-file-via-the-linux-command-line]

[링크 : https://askubuntu.com/questions/115369/how-to-play-mp3-files-from-the-command-line]

'Linux' 카테고리의 다른 글

ifconfig wan  (0) 2020.12.11
dsa distributed switch architecture  (0) 2020.12.11
shuf  (0) 2020.12.08
pdsh  (0) 2020.12.04
bash $$ 변수, 배열, 반복  (0) 2020.12.04
Posted by 구차니
Linux2020. 12. 8. 18:47

 

ls dirname | shuf -n 1
find dirname -type f | shuf -n 1

 

파일들 중에 임의의 하나를 빼내는 명령어

[링크 : https://stackoverflow.com/questions/414164/how-can-i-select-random-files-from-a-directory-in-bash]

 

 

play "`ls *mp3 | shuf -n 1`"

'Linux' 카테고리의 다른 글

dsa distributed switch architecture  (0) 2020.12.11
linux command line에서 mp3 재생하기  (0) 2020.12.08
pdsh  (0) 2020.12.04
bash $$ 변수, 배열, 반복  (0) 2020.12.04
bash 배열  (0) 2020.12.04
Posted by 구차니
프로그램 사용/openHPC2020. 12. 8. 15:01
cat /proc/net//proc/net/fib_trie

[링크 : https://unix.stackexchange.com/questions/365225/how-to-get-the-ipv4-address-for-an-interface-from-proc]

'프로그램 사용 > openHPC' 카테고리의 다른 글

OpenFabrics interface - ofi  (0) 2020.12.14
MVAPICH2  (0) 2020.12.14
centos kernel update  (0) 2020.12.08
centos kernel이 사라졌다 -ㅁ-  (0) 2020.12.08
wwmkchroot  (0) 2020.12.07
Posted by 구차니
프로그램 사용/openHPC2020. 12. 8. 11:50

 

# yum update kernel
Last metadata expiration check: 20:00:35 ago on Mon 07 Dec 2020 01:42:34 AM EST.
Dependencies resolved.
Nothing to do.
Complete!

# grub2-editenv list
saved_entry=c324aa0738b34f58b1304edca552d426-4.18.0-193.28.1.el8_2.x86_64
kernelopts=root=/dev/mapper/cl-root ro crashkernel=auto resume=/dev/mapper/cl-swap rd.lvm.lv=cl/root rd.lvm.lv=cl/swap
boot_success=0

# grub2-set-default 0

 

 

 

[링크 : https://jeongyd.tistory.com/56]

 

+

위의 방식으로 되지 않아서 다른 방법 찾는중

그런데 yum clean all 은 웬지 설치된 패키지 전부 지우는 느낌인데..

 

sudo yum check-update
sudo yum clean all
sudo reoot
sudo yum update

[링크 : https://phoenixnap.com/kb/how-to-update-upgrade-centos]

'프로그램 사용 > openHPC' 카테고리의 다른 글

MVAPICH2  (0) 2020.12.14
ip, ifconfig 없이 ip 알아내기  (0) 2020.12.08
centos kernel이 사라졌다 -ㅁ-  (0) 2020.12.08
wwmkchroot  (0) 2020.12.07
openHPC x86_64와 aarch64 문서 차이  (0) 2020.12.07
Posted by 구차니
프로그램 사용/openHPC2020. 12. 8. 11:40

저번주 까지만 해도 멀쩡히 잘 되었던 녀석이 갑자기 안된다.

그래서 찾아보는데.. 아무래도 구버전이 되어서 live에서 내려가 버린듯..

 

# rpm -qa | grep kernel
kernel-tools-4.18.0-193.28.1.el8_2.x86_64
kernel-modules-4.18.0-193.el8.x86_64
kernel-4.18.0-193.el8.x86_64
kernel-core-4.18.0-193.el8.x86_64
kernel-tools-libs-4.18.0-193.28.1.el8_2.x86_64
kernel-core-4.18.0-193.28.1.el8_2.x86_64
kernel-4.18.0-193.28.1.el8_2.x86_64
kernel-headers-4.18.0-193.28.1.el8_2.x86_64
kernel-modules-4.18.0-193.28.1.el8_2.x86_64

 

아무튼 설치는 했는데 다시 하려니 매치되는게 없다고 그런다...

# yum -y --installroot=$CHROOT install kernel-`uname -r`
Last metadata expiration check: 0:56:59 ago on Mon 07 Dec 2020 08:40:30 PM EST.
No match for argument: kernel-4.18.0-193.28.1.el8_2.x86_64
Error: Unable to find a match: kernel-4.18.0-193.28.1.el8_2.x86_64

 

[링크 : https://forums.centos.org/viewtopic.php?t=76325&p=320884]

[링크 : http://mirror.centos.org/centos/8/BaseOS/x86_64/os/Packages/?C=M;O=D]

[링크 : https://vault.centos.org/8.2.2004/BaseOS/x86_64/os/Packages/]

[링크 : http://rpmfind.net/linux/RPM/centos/8.2.2004/baseos/x86_64/Packages/kernel-4.18.0-193.el8.x86_64.html]

'프로그램 사용 > openHPC' 카테고리의 다른 글

ip, ifconfig 없이 ip 알아내기  (0) 2020.12.08
centos kernel update  (0) 2020.12.08
wwmkchroot  (0) 2020.12.07
openHPC x86_64와 aarch64 문서 차이  (0) 2020.12.07
nagios  (0) 2020.12.07
Posted by 구차니
개소리 왈왈/컴퓨터2020. 12. 7. 20:50

팩토리 모드 들어가서 패널 정보를 보니

아뿔사...

 

픽셀 형식 RGBW Vertical Stripe

[링크 : https://www.lcds-center.kr/product_LG-Display_LC430DGJ-SKA4.html]

 

 

멀 설정하던 왜이렇게 어른거리나 했더니

패널 자체가 그렇게 욕 쳐드시던 RGBW 패널이라 그렇구나.. ㅠㅠ

다음번에는 RGB 패널로 꼭 찾아서 사야지.. 아흑...

 

+

60Hz는 뜨는데 정작 설정하면 화면이 전혀 나오지 않다가

시간이 지나서 원래대로 30Hz로 돌아가면서 나온다. 도대체 이 녀석 정체가 머냐..

Posted by 구차니
embeded/raspberry pi2020. 12. 7. 18:35

 

localhost:1880/ui

[링크 : https://flows.nodered.org/node/node-red-dashboard]

[링크 : https://randomnerdtutorials.com/getting-started-with-node-red-dashboard/]

 

 

사용법

[링크 : https://ko.howtodogood.com/76628-Node-Red-Control-RaspberryPi-38]

[링크 : https://blog.naver.com/edblab/221495131985]

[링크 : https://blog.naver.com/edblab/221446658416]

 

음악 재생

[링크 : https://discourse.nodered.org/t/playing-a-mp3-flie/18030/2]

'embeded > raspberry pi' 카테고리의 다른 글

mpicc on rpi  (0) 2020.12.15
node-red UI bashboard  (0) 2020.12.08
node-red rpi  (0) 2020.11.29
간만에 라즈베리 + 포맷?  (0) 2020.11.29
라즈베리 파이 3B 환상이 너무 컸나?  (0) 2020.10.25
Posted by 구차니
Linux/Ubuntu2020. 12. 7. 17:51

설정에서 한글 입력기를 추가로 설정을 해주어야 한다.

외산 노트북이라 한영키가 없다 보니 기본 설정으로는 안되고

오른쪽 alt 를 추가해주어도 한영 변환이나

오른쪽 ctrl로 한자 변환이 되지 않는다 -_ㅠ

ibus라 그런가.. 다른걸로 해봐야하나?

 

[링크 : https://velog.io/@yujo/Ubuntu-20.04한글-입력기-설치-설정하기]

'Linux > Ubuntu' 카테고리의 다른 글

ubuntu gnome-control-center over ssh  (0) 2021.04.14
우분투 패키지 버전 확인하기  (0) 2020.12.16
/dev/ipmi를 보고 싶다!!!  (0) 2020.11.07
우분투에서 부팅 USB 만들기(iso)  (0) 2020.10.06
jaaa - JACK and ALSA Audio Analyser  (0) 2020.10.05
Posted by 구차니
프로그램 사용/openHPC2020. 12. 7. 17:10

warewulf 유틸리티인데 스크립트였네?

# cat /usr/bin/wwmkchroot
#!/bin/bash
#
#
# Copyright (c) 2001-2003 Gregory M. Kurtzer
#
# Copyright (c) 2003-2011, The Regents of the University of California,
# through Lawrence Berkeley National Laboratory (subject to receipt of any
# required approvals from the U.S. Dept. of Energy).  All rights reserved.
#
# $Id: wwmkchroot 913 2012-04-19 00:33:31Z gmk $

prefix="/usr"
exec_prefix="/usr"
libexecdir="/usr/libexec"


usage() {
    echo "$0 [options] TEMPLATE_NAME PATH"
    echo
    echo "OPTIONS:"
    echo "    -d        Debug output"
    echo "    -g        Disable install GPG checks"
    echo "    -v        Verbose output"
    echo "    -h        Show usage"
    echo
    echo "TEMPLATE_NAME (select one of the following):"
    for i in $libexecdir/warewulf/wwmkchroot/*.tmpl; do
        NAME=`basename $i | sed -e 's/\.tmpl$//'`
        DESC=`grep '^#DESC: ' $i | sed -e 's/#DESC: //'`
        printf "   * %-20s %s\n" "$NAME" "$DESC"
    done
    echo
    echo "PATH:"
    echo "   This is the location where the VNFS will be created"
    echo
    echo "EXAMPLES:"
    echo
    echo " # wwmkchroot rhel-generic /var/chroots/rhel"
    echo " # wwmkchroot debian8-64 /var/chroots/deb8"
    echo
}

unset VERBOSE
unset DEBUG
unset NOGPGCHECK
DEVNULL="/dev/null"

### Argument processing
while getopts ":dhvg" opt; do
    case $opt in
        d)
            VERBOSE=1
            DEBUG=1
            DEVNULL="/dev/stdout"
            set -x
        ;;
        v)
            VERBOSE=1
        ;;
       \?)
            printf "ERROR: $OPTARG not recognized.\n\n" 1>&2
            usage
            exit 1
        ;;
        h)
            usage
            exit 0
        ;;
        g)
            NOGPGCHECK=1
        ;;
    esac
done

shift $((OPTIND-1))

export VNFSTEMPLATE=$1
shift
export CHROOTDIR=$1
shift

if [ -z "$VNFSTEMPLATE" ]; then
    printf "ERROR: Missing VNFS template name\n\n"
    usage
    exit 1
fi

#### Check for template directory
if ! [ -d "$libexecdir/warewulf/wwmkchroot" ]; then
    echo "ERROR: Template directory ($libexecdir/warewulf/wwmkchroot) does not exist!"
    exit 1
fi

pushd $libexecdir/warewulf/wwmkchroot >$DEVNULL

#### Load functions
test -n "$VERBOSE" && printf "\n==== Loading general template functions\n"
if [ -f "./functions" ]; then
    . "./functions"
else
    echo "ERROR: Can not find $libexecdir/warewulf/wwmkchroot/functions"
    exit 1
fi

#### Load OS templates
test -n "$VERBOSE" && printf "\n==== Loading template\n"
if [ -f "$VNFSTEMPLATE.tmpl" ]; then
    test -n "$VERBOSE" && echo "Using $libexecdir/warewulf/wwmkchroot/$VNFSTEMPLATE.tmpl"
    . "$VNFSTEMPLATE.tmpl"
else
    echo "ERROR: Can not find $libexecdir/warewulf/wwmkchroot/$VNFSTEMPLATE.tmpl"
    exit 1
fi

popd >$DEVNULL

if [ -z "$CHROOTDIR" ]; then
    echo "ERROR: You must define the directory to build the chroot"
    usage
    exit 1
fi

#### Running template functions
test -n "$VERBOSE" && printf "\n==== Starting chroot build\n"
for function in $FUNCTIONS; do
    test -n "$VERBOSE" && echo "== Running: $function"
    $function || exit 1
done

 

실행하다 보면 /usr/libexec/warewulf/wwmkchroot/*.tmpl을 건드리는데

# cat centos-8.tmpl
#DESC: Red Hat Enterprise Linux 8

# The general RHEL include has all of the necessary functions, but requires
# some basic variables specific to each chroot type to be defined.

# Use DNF as the package manager
PKG_MGR=dnf
EXTRA_ARGS="--releasever=8"
PLATFORMID="platform:el8"

# Uncomment to disable GPG checks on added repos
# REPO_NOGPGCHECK=1

. include-rhel

# Define the location of the YUM repository
if [ -z "$YUM_MIRROR" ]; then
    if [ -z "$YUM_MIRROR_BASE" ]; then
        YUM_MIRROR_BASE="http://mirror.centos.org/centos-8"
    fi
    YUM_MIRROR="${YUM_MIRROR_BASE}/8/BaseOS/\$basearch/os","${YUM_MIRROR_BASE}/8/AppStream/\$basearch/os","${YUM_MIRROR_BASE}/8/PowerTools/\$basearch/os"
fi

# Install only what is necessary/specific for this distribution
PKGLIST="basesystem bash chkconfig coreutils e2fsprogs ethtool
    filesystem findutils gawk grep initscripts iproute iputils
    net-tools nfs-utils pam psmisc rsync sed setup
    shadow-utils rsyslog tzdata util-linux words
    zlib tar less gzip which util-linux openssh-clients
    openssh-server dhclient pciutils vim-minimal shadow-utils
    strace cronie crontabs cpio wget redhat-release hostname grub2-common glibc-langpack-en"

 

그 경로를 하나씩 내려가다 보니 아래와 같이 BaseOS 다음에 platform architecutre 구분이 들어가게 된다.

mirror.centos.org/centos-8/8/BaseOS/

mirror.centos.org/centos-8/8/BaseOS/aarch64/

mirror.centos.org/centos-8/8/BaseOS/x86_64/

 

해당 부분에 대해서는

$basearch 변수를 사용하는데 그걸 바꾸어서 적용하면 임의로 크로스 플랫폼(?)으로 적용이 가능할 지도 모르겠다.

 

And also need to change $YUM_MIRROR to the local repository.

Corresponds to wwmkchroot written in "3.6 Define compute image for provisioning" of each Usage.

[root@aarch64 /]# export YUM_MIRROR=""/repos/centos-<version>.<release>/BaseOS", "/repos/centos-<version>.<release>/AppStream", "/repos/centos-<version>.<release>-aarch64/PowerTools""
[root@aarch64 /]# wwmkchroot -d centos-<version> $CHROOT

[링크 : https://github.com/NaohiroTamura/cross-sms-aarch64.sh/blob/master/README.md]

 

 

'프로그램 사용 > openHPC' 카테고리의 다른 글

centos kernel update  (0) 2020.12.08
centos kernel이 사라졌다 -ㅁ-  (0) 2020.12.08
openHPC x86_64와 aarch64 문서 차이  (0) 2020.12.07
nagios  (0) 2020.12.07
openHPC LBNL NHC  (0) 2020.12.07
Posted by 구차니
프로그램 사용/openHPC2020. 12. 7. 14:48

나머지는 uname -r로

# uname -r
4.18.0-193.el8.x86_64

커널 버전과 아키텍쳐를 받아와서 티가 안나는데

초기 설치하는 패키지가 다르다.

 

[sms]# yum install http://repos.openhpc.community/OpenHPC/2/CentOS_8/x86_64/ohpc-release-2-1.el8.x86_64.rpm

[sms]# yum install http://repos.openhpc.community/OpenHPC/2/CentOS_8/aarch64/ohpc-release-2-1.el8.aarch64.rpm

 

혹시나 해서 x86 linux에 aarch64 패키지를 설치해 보았지만 역시나 에러가 발생한다.

dose not have a compatible architecture

문서 자체가 arm64 코어 기반 하드웨어가 node master여야 하는 듯..

# yum install http://repos.openhpc.community/OpenHPC/2/CentOS_8/aarch64/ohpc-release-2-1.el8.aarch64.rpm
CentOS-8 - AppStream                            2.7 kB/s | 4.3 kB     00:01
CentOS-8 - Base                                 3.7 kB/s | 3.9 kB     00:01
CentOS-8 - Extras                               1.2 kB/s | 1.5 kB     00:01
OpenHPC-2 - Base                                2.0 kB/s | 1.5 kB     00:00
OpenHPC-2 - Updates                             3.4 kB/s | 2.9 kB     00:00
Extra Packages for Enterprise Linux Modular 8 - 3.4 kB/s | 8.5 kB     00:02
Extra Packages for Enterprise Linux 8 - x86_64  2.6 kB/s | 4.8 kB     00:01
Extra Packages for Enterprise Linux 8 - x86_64  1.3 MB/s | 8.5 MB     00:06
ohpc-release-2-1.el8.aarch64.rpm                 13 kB/s |  10 kB     00:00
Error:
 Problem: conflicting requests
  - package ohpc-release-2-1.el8.aarch64 does not have a compatible architecture
(try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

 

 

+

cross 나오는것 봐서는 x86-64에서 aarch64의 VNFS를 만들도록 하는 내용 같긴한데..

[링크 : https://github.com/NaohiroTamura/cross-sms-aarch64.sh/blob/master/README.md]

'프로그램 사용 > openHPC' 카테고리의 다른 글

centos kernel이 사라졌다 -ㅁ-  (0) 2020.12.08
wwmkchroot  (0) 2020.12.07
nagios  (0) 2020.12.07
openHPC LBNL NHC  (0) 2020.12.07
openHPC 설치 part2?  (0) 2020.12.04
Posted by 구차니