Ubuntu

Ubuntu 20.04 upgrade, Python missing libffi.so.6

谁说胖子不能爱 提交于 2021-01-20 18:47:25
问题 I recently upgraded my OS to Ubuntu 20.04 LTS. Now when I try to import a library like Numpy in Python, I get the following error: ImportError: libffi.so.6: cannot open shared object file: No such file or directory I tried installing the libffi package, but apt can't locate it : sudo apt-get install libffi Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package libffi 回答1: If you are using pyenv, you should just uninstall the used

Install jq JSON processor on Ubuntu 10.04

大兔子大兔子 提交于 2021-01-20 18:45:28
问题 Is there a way to install jq JSON processor on Ubuntu 10.04? I Tried the usual sudo apt-get install jq but got the error E: Couldn't find package jq 回答1: It is possible to perform sudo apt-get install jq however you need to inform the system where to find jq. ℹ️ Note : Ubuntu 14+ users can skip to step 4! 🎉 Install Open your sources file in a text editor: sudo vim /etc/apt/sources.list Add the following line to the end of that file (note deb is not a command, more info): deb http://us.archive

Ubuntu 20.04 upgrade, Python missing libffi.so.6

倾然丶 夕夏残阳落幕 提交于 2021-01-20 18:45:07
问题 I recently upgraded my OS to Ubuntu 20.04 LTS. Now when I try to import a library like Numpy in Python, I get the following error: ImportError: libffi.so.6: cannot open shared object file: No such file or directory I tried installing the libffi package, but apt can't locate it : sudo apt-get install libffi Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package libffi 回答1: If you are using pyenv, you should just uninstall the used

Install jq JSON processor on Ubuntu 10.04

南楼画角 提交于 2021-01-20 18:45:06
问题 Is there a way to install jq JSON processor on Ubuntu 10.04? I Tried the usual sudo apt-get install jq but got the error E: Couldn't find package jq 回答1: It is possible to perform sudo apt-get install jq however you need to inform the system where to find jq. ℹ️ Note : Ubuntu 14+ users can skip to step 4! 🎉 Install Open your sources file in a text editor: sudo vim /etc/apt/sources.list Add the following line to the end of that file (note deb is not a command, more info): deb http://us.archive

Yarn install command error No such file or directory: 'install'

落花浮王杯 提交于 2021-01-20 14:10:18
问题 I am installing sylius bundle and while install sylius I need to run yarn install So While i run command yarn install I get error: ERROR: [Errno 2] No such file or directory: 'install' 回答1: I had the same issue on Ubuntu 17.04. This solution worked for me: sudo apt remove cmdtest sudo apt remove yarn curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list sudo apt-get update sudo

Yarn install command error No such file or directory: 'install'

笑着哭i 提交于 2021-01-20 14:08:40
问题 I am installing sylius bundle and while install sylius I need to run yarn install So While i run command yarn install I get error: ERROR: [Errno 2] No such file or directory: 'install' 回答1: I had the same issue on Ubuntu 17.04. This solution worked for me: sudo apt remove cmdtest sudo apt remove yarn curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list sudo apt-get update sudo

How do I fetch lines before/after the grep result in bash?

孤街醉人 提交于 2021-01-20 14:08:35
问题 I want a way to search in a given text. For that, I use grep : grep -i "my_regex" That works. But given the data like this: This is the test data This is the error data as follows . . . . . . . . . . . . . . . . . . . . . . Error data ends Once I found the word error (using grep -i error data ), I wish to find the 10 lines that follow the word error . So my output should be: . . . . . . . . . . . . . . . . . . . . . . Error data ends Are there any way to do it? 回答1: You can use the -B and -A

Yarn install command error No such file or directory: 'install'

给你一囗甜甜゛ 提交于 2021-01-20 14:08:32
问题 I am installing sylius bundle and while install sylius I need to run yarn install So While i run command yarn install I get error: ERROR: [Errno 2] No such file or directory: 'install' 回答1: I had the same issue on Ubuntu 17.04. This solution worked for me: sudo apt remove cmdtest sudo apt remove yarn curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list sudo apt-get update sudo

How do I fetch lines before/after the grep result in bash?

半世苍凉 提交于 2021-01-20 14:05:45
问题 I want a way to search in a given text. For that, I use grep : grep -i "my_regex" That works. But given the data like this: This is the test data This is the error data as follows . . . . . . . . . . . . . . . . . . . . . . Error data ends Once I found the word error (using grep -i error data ), I wish to find the 10 lines that follow the word error . So my output should be: . . . . . . . . . . . . . . . . . . . . . . Error data ends Are there any way to do it? 回答1: You can use the -B and -A

What's the reason Docker Ubuntu official image would exit immediately when you run/start it?

喜夏-厌秋 提交于 2021-01-20 13:14:12
问题 I understand that a container will exit when the main process exit. My question is about the reason behind it, not how to get it to work. I of course know that I could pass the parameter -it to start with interactive mode. The Ubuntu image will run /bin/bash when it starts according to the image Dockerfile. Shouldn't bash process wait for user input commands and not exit? (just like when you run /bin/bash in the host machine, it would start an interactive shell and wait for user inputs and