Tag Archives: ubuntu

linux VMware Unable to change virtual machine power state: Internal error

Linux installation of VMWare under a problem, recently due to project needs, we have to Fedora8 system to install a virtual machine, the above run a Windows Server 2003, after a hard time to find a Linux version of VMWare, after installation, every time you start the virtual machine will report.

Unable to change the power state of the virtual machine: internal error.
This is an error.
At first I thought there was a problem with the vmware settings, but I finally found the answer on the Internet:
I encountered this problem when running a Vmware workstation under Ubuntu Jaunty. I get an error when shutting down the machine via an NX session.
It’s the result of a zombie ‘vmware-vmx’ process running. All you need to do is kill the process. This command sends ‘signal 9’ to the process. When sent to the process, SIGKILL causes the process to terminate immediately. Contrary to SIGTERM and SIGINT, this signal cannot be captured or ignored. More info:More sigkill info.
After that, I was able to start the virtual machine without any problems.

(Windows+xrdp+ubuntu16.04) Remote server error: “password failed error-problem connecting”

Don’t be long-winded, give the problem and solution directly.

Problems that arise

The solution
Modify /etc/xrdp/sesman.ini

    open file /etc/xrdp/sesman.ini
sudo vim /etc/xrdp/sesman.ini

sesman.ini file contents are as follows:

[Globals]
ListenAddress=127.0.0.1
ListenPort=3350
EnableUserWindowManager=1
UserWindowManager=startwm.sh
DefaultWindowManager=startwm.sh

[Security]
AllowRootLogin=1
MaxLoginRetry=4
TerminalServerUsers=tsusers
TerminalServerAdmins=tsadmins

[Sessions]
X11DisplayOffset=10
MaxSessions=10
KillDisconnected=0
IdleTimeLimit=0
DisconnectedTimeLimit=0

[Logging]
LogFile=/var/log/xrdp-sesman.log
LogLevel=DEBUG
EnableSyslog=0
SyslogLevel=DEBUG

[X11rdp]
param1=-bs
param2=-ac
param3=-nolisten
param4=tcp

[Xvnc]
param1=-bs
param2=-ac
param3=-nolisten
param4=tcp
param5=-localhost
param6=-dpi
param7=96

    under [Xvnc] param8= -securitytypes and param9=None
[Xvnc]
param1=-bs
param2=-ac
param3=-nolisten
param4=tcp
param5=-localhost
param6=-dpi
param7=96
param8=-SecurityTypes
param9=None

    restart XRDP service
sudo service xrdp restart

Iphone network data is shared to ubuntu14.04 through ubs, which is a desktop computer and cannot be passed through hotspot

Unable to mount iPhone unhandled lock error
Ayes, 13 Nays, Accept
Here’s what worked for me (from immobiledevice.org):
Close the error when your device is plugged in. Then run the

idevicepair unpair && idevicepair pair

Pro test: I do not know why sometimes the implementation of no use, plug in the computer, restart the computer to go…
Then unplug your device and plug it back in.
Pro can do it
langxw@le:~$ idevicepair unpair & & idevicepair pair
The program ‘idevicepair’ is currently not installed. You can install it by typing:
sudo apt-get install libimobiledevice-utils
langxw@le:~$ sudo apt-get install libimobiledevice-utils

How to Fix error reported by rqt_plot tool in ROS

Install python PIP
You can determine whether it is installed by using the following command:

pip --version     # Python2.x 
pip3 --version    # Python3.x 

If not already installed, Ubuntu can be installed using the following methods:

sudo apt-get install python-pip

Upgrade matplotlib
View the matplotlib version

pip show matplotlib

And then upgrade

pip install --upgrade matplotlib

Then run rqt_plot

rosrun rqt_plot rqt_plot

[How to Fix] dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)

1. Problem: There is a dependency problem during the Ubuntu software installation process

 “E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).” 

The following two commands as instructed did not solve the problem.

sudo apt-get -f install
sudo apt-get --fix-broken install

Instead, the problem of “DPkg-deb: error: paste subprocess was killed by signal (Broken pipe)” appeared again

Preparing to unpack .../ros-melodic-moveit-core_0.10.8-0bionic.20181227.040044_amd64.deb ...
Unpacking ros-melodic-moveit-core (0.10.8-0bionic.20181227.040044) over (0.10.5-0bionic.20181117.193206) ...
dpkg: error processing archive /var/cache/apt/archives/ros-melodic-moveit-core_0.10.8-0bionic.20181227.040044_amd64.deb (--unpack):
 trying to overwrite '/opt/ros/melodic/include/moveit/collision_distance_field/collision_detector_allocator_distance_field.h', which is also in package ros-melodic-moveit-experimental 0.10.5-0bionic.20181117.194840
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/ros-melodic-moveit-core_0.10.8-0bionic.20181227.040044_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Final solution:

sudo apt-get autoremove ros-melodic-moveie-experimental
sudo apt-get -f install

Postscript: the origin of this problem is a legacy problem that occurred when installing ros under ubuntu18.04. As it had no impact on normal software installation, it was abandoned. However, today when installing teamviewer, I encountered a dependency problem and reported an error when -f install could not be performed. After many unsuccessful attempts to re-install ROS, I unexpectedly purge the command and failed to execute. As a result, The problem is overwhelming and I have little knowledge of the system.

Error: unrecognized command line option “-std=c++11”, to solve the problem that ubuntu does not support c++11

The cause of this compilation error is not high enough in the g++ GCC version.
Add the source

$ sudo add-apt-repository ppa:ubuntu-toolchain-r/test

$ sudo apt-get update

Install version 4.8

$ sudo apt-get install gcc-4.8 g++-4.8

View the local installation version

$ ls -lh /usr/bin/g++*

You should see that 4.6 and 4.8 are shipped.
Switch version

$ sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.6 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.6

$ sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 40 --slave /usr/bin/g++ g++ /usr/bin/g++-4.8

$ sudo update-alternatives --config gcc

here select version 4.8 serial number
Check the g++ version again

$ g++ --version

Confirm that the current version is 4.8, the problem has been solved!
From: http://my.oschina.net/chenyoca/blog/226455

Ubuntu fixes the missing dependency packages of the system (Error: Broken Count>0)

If ubuntu has a package that does not meet the dependency criteria, Error is reported :Broken Count> 0, as shown below:

The following command will automatically fix the packages on which the installation package depends:

    $ sudo apt-get install -f 

The -f parameter stands for Fix Broken.
If the fix fails and there is still a problem, confirm which application was installed earlier and then execute the following command to uninstall:

    $ apt remove xxx

After the unloading is completed, it is found that no error is reported. The figure is as follows:

Ubuntu fixes the system’s missing dependency package to this solution.

Install ubuntu system, report error WslRegisterDistribution failed with error: 0x8007019e

Installing ubuntu on the Windows App Store, WslRegisterDistribution failed with error: 0x8007019e
1. An error:

Installing, this may take a few minutes...
Installation Failed!
Error: 0x8007019e
Press any key to continue...

 
2. Reason:
Windows subsystem support is not installed.
 

3. Solution:
1. Win +x, select Windows PowerShell (administrator)
2. Input:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

3. Enter, type Y, and restart! 4. Reopen the installed subsystem, wait a few minutes, and enter your account and password.

How to solve the problem of Cannot find module’npmlog’ when installing nodejs under Linux

I used Ubuntu version of Linux, downloaded nodeJS6 executable file compression package from nodeJS official website, extracted it into folder under the Window, and uploaded it to Linux server through WinSCP.
Configure environment variables:
Add a nodejs.sh script under /etc/profile.d/, which reads as follows:

export NODE_HOME=/home/TECS/nodejs/node-v6.11.1-linux-x64
export PATH=$PATH:$NODE_HOME/bin
export NODE_PATH=$NODE_HOME/lib/node_modules

If you want to make the configuration work without restarting the machine, repeat the three commands from the command line.
Running NPM-V at this time Cannot find Module ‘NPMLOG’ error.
The solution
CD command enter /home/TECS/nodejs/node-v6.11.1-linux-x64/bin then execute the following command to establish the soft connection:

ln -s ../lib/node_modules/npm/bin/npm-cli.js

The generated NPM-cli.JS soft connection is then renamed to NPM. The original NPM file is not available.

mv npm-cli.js npm

Solution to stray’\357′ in program when gcc is compiled

Link: http://blog.chinaunix.net/uid-23089249-id-61541.html

I got a few header files from my colleagues. It’s ok to compile with GCC, but a whole bunch of them came up when I compiled with ARM-Linux-gcc!

SerialPort.h:1: error: stray ‘\357’ in program

SerialPort.h:1: error: stray ‘\273’ in program

SerialPort.h:1: error: stray ‘\277’ in program

Look at these errors confused, after looking up the Internet, found that some characters in the file compiler does not support. If you look for these characters one by one, you’ll probably be looking for a long time! The simplest solution:
Put the files into The Windows system, use “Notepad” to open these files, and then “save as”, choose the code ASNI, and then under Linux to re-compile with the compiler, generally can pass!

Experience:

The first time: unknown;

Second time: when compiling QT program, prompt this error; According to the above method solved.

Ubuntu network configuration+Fixing “Failed to bring up eth0” in Ubuntu

When I installed Ubuntu Server on one machine, the installation process skipped the step of network configuration, and When I logged in this machine via SSH on another machine, I was still unable to connect. Looking through the list of router DHCP Client Table, I found that the machine installing Ubuntu Server was not connected to the network, which was very strange.
$ifconfig
returns lo instead of eth0, which may be related to skipping network configuration during installation. Simply configure this machine to join the network normally.
$sudo pico /etc/network/interfaces
this will launch a simple text editor to edit Linux network configuration files
which you should see here:

auth lo
iface lo inet loopback

is exactly the lo loop. I need this machine running Ubuntu Server to get IP through DHCP to join the network. Then I just need to add the following configuration content of the lo loop above:

auth eth0
iface eth0 inet dhcp

press
Ctrl+O to save, press Ctrl+X to exit.

There are two ways to get your network configuration files into effect:
1, restart Ubuntu:

$sudo reboot
2, restart network components:

$sudo /etc/init.d/networking restart

as long as shown
Reconfiguring network interfaces… [OK]

is a successful restart of the network component.

if the IP is required instead of being obtained by DHCP
Manually specify the IP (such as 192.168.1.1) and specify the gateway (such as 192.168.1.254), then configure as follows:

Auth eth0
iface eth0 inet static
address 192.168.1.1
netmask 255.255.255.0
gateway 192.168.1.254

if you are manually specifying IP and you also need to access the Internet, such as wget download, then you also need to set DNS:

$sudo pico /etc/resolv.conf

to add configuration content here:

nameserver xxx.xxx.xxx.xxx

just save.

The attached:
Fixing “Failed to bring up eth0” in Ubuntu

1.
sudo /etc/init.d/networking restart

 

2,
ifconfig -a

3,
sudo vi /etc/network/interface

4.
sudo /etc/init.d/networking restart

5,
ifconfig

 

or

 

sudo rm /etc/udev/rules.d/70-persistent-net.rulessudo rm /etc/udev/rules.d/70-persistent-net.rulessudo rm /etc/udev/rules.d/70-persistent-net.rulessudo rm /etc/udev/rules.d/70-persistent-net.rules

The network card is fine after the reboot.