AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-345822

Gman's questions

Martin Hope
Gman
Asked: 2015-11-13 03:22:14 +0800 CST

使用 grep/sed/awk 从字符串中提取单词

  • 12

我有一个字符串

00:28:04 /usr/lib/jvm/jre/bin/java -DJDBC_CONNECTION_STRING= -Dspring.profiles.active=qa -XX:MaxPermSize=256

并想提取后面的qa单词-Dspring.profiles.active。

我将字符串保存在文件 text.txt 中只是为了演示它。

当我做

grep -r -o "spring.profiles.active=" text.txt

结果是spring.profiles.active=

这个词并不总是qa,它可能是prod或dev。

我想做的是找到这个词spring.profiles.active并在=提取那个词之后。

我想编写 shell 脚本,因为我使用这个词来配置服务器上的其他项目。

这可能吗?如果可以,我该怎么做。

command-line
  • 3 个回答
  • 104659 Views
Martin Hope
Gman
Asked: 2015-07-02 05:34:17 +0800 CST

mvn --version -Dmaven.multiModuleProjectDirectory 系统属性未设置

  • 2

我已经下载并安装了maven3.3.3。在 uBuntu 14.04 上,当我运行命令时

mvn --version

我收到这个错误

-Dmaven.multiModuleProjectDirectory system propery is not set. Check $M2_HOME `enter code here`environment variable and mvn script match.

我尝试在 /etc/environment 中设置环境

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/opt/apache-maven-3.3.3/bin"

JAVA_HOME="/usr/lib/jvm/java-8-oracle/jre"

MAVEN_OPTS="-Xms1024m -Xmx2048m -Dmaven.surefire.debug=-Xmx2048m -XX:MaxPermSize=128m"

M2_HOME="/opt/apache-maven-3.3.3"

对你的帮助表示感谢

G

maven-3
  • 1 个回答
  • 13476 Views
Martin Hope
Gman
Asked: 2015-02-15 18:23:13 +0800 CST

无法登录我的 ubuntu 笔记本电脑,登录循环

  • 3

任何人都可以帮助我,我无法登录我的笔记本电脑。看起来它只是循环回到登录屏幕。

可能是什么原因造成的,我在 AWS EC2 实验室工作,在设置实例后,我下载了 PEM/PPK,将其保存在一个文件夹中。然后我不得不打开终端并输入chmod 600 ~/ <pathToPem>see Image below,我得到了一个错误所以我把sudo chmod 600 ~/ pathname. (几乎可以肯定这就是我遇到问题的原因)当我运行第二个命令时它找不到路径,当我检查家里的文件/文件夹时很多东西都消失了?所以在那只雄鹿我注销并尝试重新登录但似乎陷入了循环。

谁能帮我回去并撤消我所做的事情。我可以获取文本登录并以这种方式获取,但似乎无权执行任何操作。

试图运行ls -la .Xauthority并获取 ls:无法访问 .Xauthority:没有这样的文件或目录。

在此处输入图像描述

command-line
  • 1 个回答
  • 2152 Views
Martin Hope
Gman
Asked: 2015-01-25 03:48:14 +0800 CST

Faststone Image Resizer 等效于 Ubuntu

  • 1

我正在(逐渐)从 Windows 转移到 Ubuntu,并使用 Faststone Image Resizer for Windows 一段时间,发现它非常好。

有人可以向我推荐适用于 Ubuntu 的等效软件吗?

software-recommendation
  • 1 个回答
  • 4642 Views
Martin Hope
Gman
Asked: 2015-01-14 06:20:02 +0800 CST

无法从 ubuntu 连接到 eduroam

  • 6

我正在尝试从 Ubuntu 连接到 eduroam,它要求我提供证书。我问过我的大学技术支持,得到的答案是“我对 Linux 或 Ubuntu 一无所知,我们所有的机器都是 Windows 或 Mac”。我问了一位讲师,他说不需要证书。

我该如何解决?

wireless
  • 2 个回答
  • 15710 Views
Martin Hope
Gman
Asked: 2015-01-13 03:51:13 +0800 CST

顶部面板上的红色三角形通知

  • 1

我在顶部面板上有一个红色三角形,上面写着 The update information is outdated. This may be caused by network problems or by a repository that is no longer available. Please update manually by selecting show updates from the indicator menu and watching for any failing repositories.

我的 Ubuntu 是最新的。打开笔记本电脑后需要一些时间才能出现,即使 Ubuntu 是最新的,它也总是会返回。

输出sudo apt-get upgrade:


Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
  libbit-vector-perl libcarp-clan-perl libclass-method-modifiers-perl
  libdata-random-perl libdate-calc-perl libdate-calc-xs-perl libgd-perl
  libgnome2-gconf-perl libmouse-perl libnet-dropbox-api-perl
  linux-headers-3.13.0-32 linux-headers-3.13.0-32-generic
  linux-image-3.13.0-32-generic linux-image-extra-3.13.0-32-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

这是输出sudo apt-get update:


Ign http://ppa.launchpad.net trusty InRelease                                  
Ign http://ppa.launchpad.net trusty InRelease                                  
Ign http://ppa.launchpad.net trusty InRelease                                  
Ign http://ppa.launchpad.net trusty InRelease                                  
Ign http://ppa.launchpad.net trusty InRelease                                  
Hit http://ppa.launchpad.net trusty Release.gpg                                
Hit http://ppa.launchpad.net trusty Release.gpg                                
Hit http://ppa.launchpad.net trusty Release.gpg                                
Hit http://ppa.launchpad.net trusty Release.gpg                                
Hit http://ppa.launchpad.net trusty Release.gpg                                
Hit http://ppa.launchpad.net trusty Release                                    
Hit http://ppa.launchpad.net trusty Release                                    
Hit http://ppa.launchpad.net trusty Release                                    
Ign http://ie.archive.ubuntu.com trusty InRelease                              
Ign http://old-releases.ubuntu.com raring InRelease                            
Hit http://ppa.launchpad.net trusty Release                                    
Ign http://ie.archive.ubuntu.com trusty-updates InRelease                      
Hit http://old-releases.ubuntu.com raring Release.gpg                          
Ign http://ie.archive.ubuntu.com trusty-backports InRelease                    
Hit http://ppa.launchpad.net trusty Release                                    
Hit http://ie.archive.ubuntu.com trusty Release.gpg                            
Hit http://old-releases.ubuntu.com raring Release                              
Hit http://ppa.launchpad.net trusty/main amd64 Packages                        
Get:1 http://ie.archive.ubuntu.com trusty-updates Release.gpg [933 B]          
Hit http://ppa.launchpad.net trusty/main i386 Packages                         
Hit http://old-releases.ubuntu.com raring/main amd64 Packages                  
Hit http://ie.archive.ubuntu.com trusty-backports Release.gpg                  
Hit http://ppa.launchpad.net trusty/main Translation-en                        
Hit http://ie.archive.ubuntu.com trusty Release                                
Hit http://old-releases.ubuntu.com raring/restricted amd64 Packages            
Get:2 http://ie.archive.ubuntu.com trusty-updates Release [62.0 kB]            
Hit http://old-releases.ubuntu.com raring/universe amd64 Packages              
Hit http://old-releases.ubuntu.com raring/multiverse amd64 Packages            
Hit http://ppa.launchpad.net trusty/main amd64 Packages                        
Hit http://old-releases.ubuntu.com raring/main i386 Packages                   
Hit http://ppa.launchpad.net trusty/main i386 Packages                         
Hit http://old-releases.ubuntu.com raring/restricted i386 Packages             
Hit http://old-releases.ubuntu.com raring/universe i386 Packages               
Hit http://ie.archive.ubuntu.com trusty-backports Release                      
Hit http://ie.archive.ubuntu.com trusty/main Sources                           
Hit http://old-releases.ubuntu.com raring/multiverse i386 Packages             
Hit http://ppa.launchpad.net trusty/main amd64 Packages                        
Hit http://ie.archive.ubuntu.com trusty/restricted Sources                     
Hit http://ppa.launchpad.net trusty/main i386 Packages                         
Hit http://ie.archive.ubuntu.com trusty/universe Sources                       
Hit http://old-releases.ubuntu.com raring/main Translation-en                  
Hit http://ppa.launchpad.net trusty/main Translation-en                        
Hit http://ie.archive.ubuntu.com trusty/multiverse Sources                     
Hit http://ie.archive.ubuntu.com trusty/main amd64 Packages                    
Hit http://ppa.launchpad.net trusty/main amd64 Packages                        
Hit http://ie.archive.ubuntu.com trusty/restricted amd64 Packages              
Hit http://old-releases.ubuntu.com raring/multiverse Translation-en            
Hit http://ppa.launchpad.net trusty/main i386 Packages                         
Hit http://ie.archive.ubuntu.com trusty/universe amd64 Packages                
Hit http://ppa.launchpad.net trusty/main Translation-en                        
Hit http://ie.archive.ubuntu.com trusty/multiverse amd64 Packages              
Hit http://old-releases.ubuntu.com raring/restricted Translation-en            
Hit http://ppa.launchpad.net trusty/main amd64 Packages                        
Hit http://ie.archive.ubuntu.com trusty/main i386 Packages                     
Hit http://ppa.launchpad.net trusty/main i386 Packages                         
Hit http://ie.archive.ubuntu.com trusty/restricted i386 Packages               
Hit http://old-releases.ubuntu.com raring/universe Translation-en              
Hit http://ie.archive.ubuntu.com trusty/universe i386 Packages                 
Hit http://ie.archive.ubuntu.com trusty/multiverse i386 Packages               
Hit http://ie.archive.ubuntu.com trusty/main Translation-en                    
Hit http://ie.archive.ubuntu.com trusty/multiverse Translation-en              
Hit http://ie.archive.ubuntu.com trusty/restricted Translation-en              
Hit http://ie.archive.ubuntu.com trusty/universe Translation-en                
Get:3 http://ie.archive.ubuntu.com trusty-updates/main Sources [152 kB]        
Ign http://old-releases.ubuntu.com raring/main Translation-en_IE               
Ign http://ppa.launchpad.net trusty/main Translation-en_IE                     
Get:4 http://ie.archive.ubuntu.com trusty-updates/restricted Sources [2,061 B] 
Ign http://old-releases.ubuntu.com raring/multiverse Translation-en_IE         
Ign http://ppa.launchpad.net trusty/main Translation-en                        
Get:5 http://ie.archive.ubuntu.com trusty-updates/universe Sources [96.5 kB]   
Ign http://old-releases.ubuntu.com raring/restricted Translation-en_IE         
Ign http://ppa.launchpad.net trusty/main Translation-en_IE                     
Ign http://old-releases.ubuntu.com raring/universe Translation-en_IE           
Ign http://ppa.launchpad.net trusty/main Translation-en                        
Get:6 http://ie.archive.ubuntu.com trusty-updates/multiverse Sources [3,543 B] 
Get:7 http://ie.archive.ubuntu.com trusty-updates/main amd64 Packages [392 kB] 
Get:8 http://ie.archive.ubuntu.com trusty-updates/restricted amd64 Packages [8,875 B]
Get:9 http://ie.archive.ubuntu.com trusty-updates/universe amd64 Packages [236 kB]
Get:10 http://ie.archive.ubuntu.com trusty-updates/multiverse amd64 Packages [9,370 B]
Get:11 http://ie.archive.ubuntu.com trusty-updates/main i386 Packages [384 kB] 
Get:12 http://ie.archive.ubuntu.com trusty-updates/restricted i386 Packages [8,846 B]
Get:13 http://ie.archive.ubuntu.com trusty-updates/universe i386 Packages [237 kB]
Get:14 http://ie.archive.ubuntu.com trusty-updates/multiverse i386 Packages [9,553 B]
Hit http://ie.archive.ubuntu.com trusty-updates/main Translation-en            
Hit http://ie.archive.ubuntu.com trusty-updates/multiverse Translation-en      
Hit http://ie.archive.ubuntu.com trusty-updates/restricted Translation-en      
Hit http://ie.archive.ubuntu.com trusty-updates/universe Translation-en        
Hit http://ie.archive.ubuntu.com trusty-backports/main Sources                 
Hit http://ie.archive.ubuntu.com trusty-backports/restricted Sources           
Hit http://ie.archive.ubuntu.com trusty-backports/universe Sources             
Hit http://ie.archive.ubuntu.com trusty-backports/multiverse Sources           
Hit http://ie.archive.ubuntu.com trusty-backports/main amd64 Packages          
Hit http://ie.archive.ubuntu.com trusty-backports/restricted amd64 Packages    
Hit http://ie.archive.ubuntu.com trusty-backports/universe amd64 Packages      
Hit http://ie.archive.ubuntu.com trusty-backports/multiverse amd64 Packages    
Hit http://ie.archive.ubuntu.com trusty-backports/main i386 Packages           
Hit http://ie.archive.ubuntu.com trusty-backports/restricted i386 Packages     
Hit http://ie.archive.ubuntu.com trusty-backports/universe i386 Packages       
Hit http://ie.archive.ubuntu.com trusty-backports/multiverse i386 Packages     
Hit http://ie.archive.ubuntu.com trusty-backports/main Translation-en          
Hit http://ie.archive.ubuntu.com trusty-backports/multiverse Translation-en    
Hit http://ie.archive.ubuntu.com trusty-backports/restricted Translation-en    
Hit http://ie.archive.ubuntu.com trusty-backports/universe Translation-en      
Ign http://ie.archive.ubuntu.com trusty/main Translation-en_IE                 
Ign http://ie.archive.ubuntu.com trusty/multiverse Translation-en_IE           
Ign http://ie.archive.ubuntu.com trusty/restricted Translation-en_IE           
Ign http://ie.archive.ubuntu.com trusty/universe Translation-en_IE             
Err http://security.ubuntu.com trusty-security InRelease                       

Err http://security.ubuntu.com trusty-security Release.gpg                     
  Could not resolve 'security.ubuntu.com'
Err http://dl.google.com stable InRelease                                      

Err http://dl.google.com stable Release.gpg                                    
  Could not resolve 'dl.google.com'
Err http://linux.dropbox.com trusty InRelease                           

Err http://linux.dropbox.com trusty Release.gpg                         
  Could not resolve 'linux.dropbox.com'
Err http://extras.ubuntu.com trusty InRelease

Err http://extras.ubuntu.com trusty Release.gpg
  Could not resolve 'extras.ubuntu.com'
Fetched 1,602 kB in 40s (39.9 kB/s)
Reading package lists... Done
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease  

W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/trusty/InRelease  

W: Failed to fetch http://linux.dropbox.com/ubuntu/dists/trusty/InRelease  

W: Failed to fetch http://dl.google.com/linux/chrome/deb/dists/stable/InRelease  

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/Release.gpg  Could not resolve 'security.ubuntu.com'

W: Failed to fetch http://dl.google.com/linux/chrome/deb/dists/stable/Release.gpg  Could not resolve 'dl.google.com'

W: Failed to fetch http://linux.dropbox.com/ubuntu/dists/trusty/Release.gpg  Could not resolve 'linux.dropbox.com'

W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/trusty/Release.gpg  Could not resolve 'extras.ubuntu.com'

W: Some index files failed to download. They have been ignored, or old ones used instead.



apt
  • 1 个回答
  • 402 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve