apt

Ubi菜鸟(三)修改source软件源,更快速地安装软件

喜欢而已 提交于 2019-11-30 17:00:20
在系统更新或是安装软件的时候,经常会遇到连接失败或是下载失败的情况。这是因为ubuntu官网的连接较慢。 通过修改source软件源(以清华)可以解决这个问题。 1 备份/etc/apt/sources.list sudo cp -r /etc/apt/sources.list /etc/apt/sources.list.bak 2 打开清华大学TUNA镜像源官网 https://mirror.tuna.tsinghua.edu.cn/ 在镜像列表中选择ubuntu,然后在右边主窗口选择当前系统的版本(以16.04为例) 复制文本框中的代码 3 用文本编辑器(以gedit为例)打开/etc/apt/sources.list(注意是sources.list不是source.list) sudo gedit /etc/apt/sources.list 在文本编辑器中将原来的内容全部替换,然后保存退出即可 使用source命令使其立即生效 source /etc/apt/sources.list 4 打开软件更新器(可以在dash中搜索),点击停止更新弹出如下对话框 点击“设置”按钮,在“其他软件”面板中取消选中archive.ubuntukylin.com...... 关闭窗口 在弹出的对话框中点击“重新载入”,或直接关闭后在运行如下命令 sudo apt update 至此,耐心等待

/bin/sh: 1: apk: not found while creating docker image

戏子无情 提交于 2019-11-30 14:40:24
问题 I have the below Dockerfile for zookeeper and I am trying to create an image for it, but it is giving me an error. I have recently started working with Docker, and started playing with a Zookeeper setup, so I am not able to understand. What does this error mean? FROM ubuntu:trusty MAINTAINER David RUN apt-get update && apt-get install -y openjdk-7-jre-headless wget ENV JAVA_HOME /usr/lib/jvm/java-7-openjdk-amd64 # Install required packages RUN apk add --no-cache \ bash \ su-exec ENV ZOO_USER

TX2 刷 Jetpack4.2 后的换源问题

大憨熊 提交于 2019-11-30 13:16:08
NVIDIA TX2 刷 Jetpack4.2后 的ARM换源问题 Keypoint: Jetpack4.2刷机过后的系统版本为ubuntu18.04 TX2 本身 为ARM64架构的 CPU Ubuntu18.04的apt软件配置文件是/etc/apt/sources.list x86 架构下的清华镜像源: ubuntu18.04软件清华源 备份:sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup 修改更新源:sudo vim /etc/apt/sources.list 上述连接中为x86架构的软件源,arm64的软件源修改如下: # 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic main restricted universe multiverse # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic main restricted universe multiverse deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/

/bin/sh: 1: apk: not found while creating docker image

大憨熊 提交于 2019-11-30 11:33:29
I have the below Dockerfile for zookeeper and I am trying to create an image for it, but it is giving me an error. I have recently started working with Docker, and started playing with a Zookeeper setup, so I am not able to understand. What does this error mean? FROM ubuntu:trusty MAINTAINER David RUN apt-get update && apt-get install -y openjdk-7-jre-headless wget ENV JAVA_HOME /usr/lib/jvm/java-7-openjdk-amd64 # Install required packages RUN apk add --no-cache \ bash \ su-exec ENV ZOO_USER=zookeeper \ ZOO_CONF_DIR=/conf \ ZOO_DATA_DIR=/data \ ZOO_DATA_LOG_DIR=/datalog \ ZOO_PORT=2181 \ ZOO

ubuntu18.04下安装eclipse+svn

橙三吉。 提交于 2019-11-30 09:32:00
安装eclipse 打开“ubuntu 软件“,搜索eclipse,找到eclipse并安装。 安装subclipse插件 SVN插件需要依赖libsvn-java,libsvn-java在写本文档时Ubuntu默认版本为1.9,而当前Eclipse Marketplace的subclipse4.3.0插件要求版本1.11,因此需安装libsvn-java1.11: sudo sh -c 'echo "deb http://opensource.wandisco.com/ubuntu ` lsb_release -cs ` svn111" >> /etc/apt/sources.list.d/subversion111.list' sudo wget -q http://opensource.wandisco.com/wandisco-debian-new.gpg -O- | sudo apt-key add - sudo apt-get remove libsvn-java sudo 来源: https://blog.csdn.net/qwt3916/article/details/101263479

[PVE]解决 ProXmoX VE升级 apt-get update 报错的问题

 ̄綄美尐妖づ 提交于 2019-11-30 08:36:57
原文出自: https://blog.csdn.net/csgd2000/article/details/81059461 vim /etc/apt/sources.list.d/pve-enterprise.list 注释掉 #deb https://enterprise.proxmox.com/debian/pve stretch pve-enterprise 也可以直接删除掉 rm -f /etc/apt/sources.list.d/pve-enterprise.list 为了更新proxmox 还需要 nano /etc/apt/sources.list 添加内容: deb http://download.proxmox.com/debian stretch pve-no-subscription echo "deb http://download.proxmox.com/debian/pve stretch pve-no-subscription" > /etc/apt/sources.list.d/pve-install-repo.list wget http://download.proxmox.com/debian/proxmox-ve-release-5.x.gpg -O /etc/apt/trusted.gpg.d/proxmox-ve-release-5.x

APT (Annotation Processing Tool)

▼魔方 西西 提交于 2019-11-30 08:31:06
I was trying to find simple example to understand the usage of apt command, but I couldn't find a helpful resource for this. I have referred this Getting Started with the Annotation Processing Tool but I do get a high level understanding. Moreover I want to write a code to test apt command. Can somebody post a simple example or better link to refer? kschneid Here's an example of creating a Note annotation and associated processor: APT: Compile-Time Annotation Processing with Java Update. As of Java 1.7: JSR 269, also known as the Language Model API, has two basic pieces: an API that models the

How to update-alternatives to Python 3 without breaking apt?

人盡茶涼 提交于 2019-11-30 06:47:09
问题 The other day I decided that I wanted the command python to default to firing up python3 instead of python2. So I did this: sudo update-alternatives --install /usr/bin/python python /usr/bin /python2.7 2 sudo update-alternatives --install /usr/bin/python python /usr/bin/python3.5 3 sudo update-alternatives --config python $ sudo update-alternatives --config python There are 2 choices for the alternative python (providing /usr/bin/python). Selection Path Priority Status -----------------------

Ubuntu搭建LAMP和LNMP环境

随声附和 提交于 2019-11-30 06:31:51
操作环境:Ubuntu 18.04.1 搭建LAMP环境: 图形界面配置更新Ubuntu源: 在VMware打开Ubuntu,依次打开系统设置,软件和更新。在下载自中选择其他站点,然后在中国的条目下选择mirrors.ustc.edu.cn。 更新资源包和软件: sudo apt update&& sudo apt upgrade sudo apt dist-upgrade&&sudo apt autoclean 清除不需要的软件和文件: sudo apt autoclean&&sudo apt autoremove 安装apache: sudo apt install apache2 默认的配置文件:/etc/apache2/sites-enabled/000-default.conf 默认安装源码的位置(网站根目录):/var/www/html 检查apache是否开启: sudo service apache2 status 显示active(running)则表示已开启。 相关命令:   开启apache:service apache2 start   关闭apache:service apache2 stop   重启apache:service apache2 restart 检查apache默认使用的80端口是否开启: netstat -ntulp | grep 80

10_ubuntu换源(其他linux发行版类似)

旧城冷巷雨未停 提交于 2019-11-30 03:08:57
linux 换源 清华大学开源软件镜像站地址: https://mirrors.tuna.tsinghua.edu.cn/ 流程: 打开清华大学镜像站 找到ubuntu, 点击ubuntu 后面的那个问号 在点击问号打开的容器中,选择你的ubuntu版本 确定好版本后,复制下面的文本内容, 新建文件 sources.list , 把复制的内容拷贝到 sources.list 文件内 删除/etc/apt/sources.list 文件 sudo rm /etc/apt/sources.list 把 新建的sources.list文件拷贝到/etc/apt/下 sudo cp sources.list /etc/apt/ 更新源: sudo apt update 为了防止出错,可以先备份Ubuntu默认的源地址 sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup 来源: https://www.cnblogs.com/nichengshishaonian/p/11549298.html