Tag Archives: linux

Adding a reference in the system-user.dtsi file cannot modify the device tree file pl.dtsi

Project Scenario:
when creating a petalinux system using Xilinx’s petalinux tool, modify the device tree file pl.dtsi by adding a reference to the system-user.dtsi file


Problem description:
cannot modify pl.dtsi configuration through system-user.dtsi


/include/ "system-conf.dtsi"
/{
};
 
&amba_pl{
    axidma_chrdev: axidma_chrdev@0 {
            compatible = "xlnx,axidma-chrdev";
            dmas = <&axi_dma_0 0 &axi_dma_0 1>;
            dma-names = "tx_channel", "rx_channel";
    };
};
 
&axi_dma_0{
    dma-channel@40400000 {
        xlnx,device-id = <0x0>;
    };
    dma-channel@40400030 {
        xlnx,device-id = <0x1>;
    };
}

Reason analysis:
system-user. Dtsi file format error, space between dma and {!!!


Solutions:
modify the code format, create system.dtb, use the following statement to reverse generate DTS file, found that part of the pl configuration has been successfully modified!

dtc -I dtb -O dts -o system.dts system.dtb

Modified code:


/include/ "system-conf.dtsi"
/{
};
 
&amba_pl {
    axidma_chrdev: axidma_chrdev@0 {
            compatible = "xlnx,axidma-chrdev";
            dmas = <&axi_dma_0 0 &axi_dma_0 1>;
            dma-names = "tx_channel", "rx_channel";
    };
};
 
&axi_dma_0 {
    dma-channel@40400000 {
        xlnx,device-id = <0x0>;
    };
    dma-channel@40400030 {
        xlnx,device-id = <0x1>;
    };
}

Results in system. DTS:

Error in sitecustomize set PYTHONVERBOSE for traceback KeyError: ‘PYTHONPATH’

Error in sitecustomize; Set PYTHONVERBOSE for traceback: KeyError: ‘PYTHONPATH’
1. Background of the problem
Python2.7 comes with Mac, and python3.6 comes with your own Anaconda installation. After the opencv installation, the following prompts

after the following installation steps are prompted, open Spyder to run the program again or use python3 on the terminal will be prompted as the question error
Reason 2.
Sys. path adds the site-package of Python27. conflict
3. Solve
To “…/local/lib/python3.6/site-packages/ “under directory (directory only for people)
execute $vim homebrew. PTH
remove the path inside
4. Exit terminal/restart Spyder without error

Edit the file to be edited by gedit. After saving, a warning of Set document metadata failed: Setting attribute metadata::gedit-position no appears

Set document metadata failed: Setting attribute metadata::gedit-position no
My situation is as follows:

About this situation can see: https://askubuntu.com/questions/798935/set-document-metadata-failed-when-i-run-sudo-gedit
The blog’s solution is that it’s just a warning, just ignore it.

(gedit:10072): dconf-WARNING **: failed to commit changes to dconf: connection closed

Problem: writing a hello.c file in Linux has reported an error

The possible reason is that the GCC source
input was not installed

rpm -q gcc


how to install GCC source in Linux
to write the simplest c program hello.c can refer to the blog below
to create c program hello.c

under root would be considered for normal users, or su-.

WordPress appears Too many failed login attempts error solution

Use idle resources to earn pocket money (suitable for school students and housewives)
Solutions:
1. Log in to the database
mysql -uroot -p
Enter the password
2. Select your database instance (e.g., my instance name is Blog)
use blog;
3. Execute the following command (the table name depends on what the prefix is and find the table with the _options suffix).
Update TB_options Set option_value= ‘where option_name=’ WAS_LIMIT_login_lockouts’;

use the idle resources of computer to earn pocket money (suitable for students and housewives)
online generating external chain tools (international version)
online generating external chain tools (Chinese version)

Raspberry Pi runs ubuntu-mate and reports Failed to start Load Kernel Modules error countermeasures

Raspberry PI installed with Ubuntu-Mate boot process appeared as follows: Failed to start Load Kernel Modules.
Solution :(comment out the three error files)
sudo nano /etc/modules-load.d/cups-filters.conf
# Parallel printer driver modules loading for cups
# LOAD_LP_MODULE was ‘yes’ in /etc/default/cups
#lp
#ppdev
#parport_pc
Note: The above solution can resolve the error, but will disable the printer. If you need to use a printer, please refer to the following article:
https://wiki.archlinux.org/index.php/CUPS_ (BD E4 AE E7% % % 80% % 93% % E6 AD B8 E4% % % % 96% 87) #. E5. AE. 89 E8. A3.85 _CUPS

unrecognized relocation (0x2a) in section `.text`

The problem
One of the libraries used today has been updated. After the new version is updated, there will be an error when compiling the Linux-x86-64 version on the server:
/usr/bin/ld: libsdk.a(Imagexxx.cpp.o): unrecognized relocation (0x2a) in section .text
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status
Then I tested it on my own computer, and the results compiled.
Based on the relevant information of see on stack overflow:
https://stackoverflow.com/questions/46058050/unable-to-compile-unrecognized-relocation
Most likely the LD version is incorrect

ld version:
GNU ld(GNU Binutils for Ubuntu) 2.26
server ld version:
GNU ld(GNU Binutils for Ubuntu) 2.24
To solve
Have root access

$ sudo apt-get update
$ sudo apt-get install binutils-2.26

export PATH="/usr/lib/binutils-2.26/bin:$PATH"

No root
download source:
https://ftp.gnu.org/gnu/binutils/

tar -zxvf binutils-2.26.tar.gz
cd binutils-2.26
./configure --prefix=/home/xxx/binutils
make
make install
export PATH="/home/xxx/binutils/bin:$PATH"

Kali linux installation guide

Carly’s guide to installing linux and avoiding potholes
1. Problem 1: The installation procedure has failed. You can try to run the failed item from the menu again, or skip it and select another item. The failed step is to install system2. grub-pc package failed to install in /target/.

1. Problem 1: The installation procedure has failed. You can try to run the failed item from the menu again, or skip it and select another item. The failed step is to install the system

Reason: Wrong partition selection.
Solution: Choose the default partition, i.e. recommend new user option.
2. grub-pc package could not be installed in /target/.

Reason: Network packet update error.
Solution: Don’t enable network update, just select no option.

Unable to register authentication agent: GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: Cannot

I just installed dvWA range environment. After debugging, I executed the SystemCTL Restart PHP-FPM command as root user, and then reported this error:

[root@localhost ~]# systemctl restart php-fpm
** (pkttyagent:10946): WARNING **: 17:09:31.957: Unable to register authentication agent: GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject
Error registering authentication agent: GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject (polkit-error-quark, 0)

Refer to such a document, found that was caused by x permissions lost, reference document links: https://blog.csdn.net/huangjin0507/article/details/51536454
The following command is used:

[root@localhost ~]# chmod 755 /

With the changes, the problem disappeared, PHP was rebooted, and DVWA was successfully accessed.


Error: Failed dependencies: error encountered when installing rpm package

Under Linux install RPM packages often encounter the following problem:
error: Failed dependencies:
… The
ellipsis indicates the missing package for installing this RPM.
when you encounter this problem, you can add two parameters after the installation of RPM package command, such as:
rpm-ivh libstdc++5.0-3.3.3-62745cl.i386. RPM
is changed to:
RPMS -ivh libstdc++5.0-3.3.3-62745cl.i386. RPM –nodeps –force

plus those two parameters mean that
is installed without having to dependencies among packets, and
does not count error: Failed dependencies: such errors
In RedHat Linux and Other RedHat compliant distributions such as Mandrake, the entire distribution is installed using RPM. So the best way to install new software is to

downloading RPM packages from the network.
1) to install a package using an RPM, the simplest command is as follows:

# rb-ivh foo-1.0l-l.is386.rpm (the package in question is foo-1.0l-l.is386.rpm, all of the following)

foo#################### ############. Installation is simple.

2) remove installed packages
to uninstall package foo, simply enter the following command:

# rpm-e foo

note: the package name is foo, not the RPM file name “foo-1.01-l.b.i. 386.rpm”.

3) upgrading packages to upgrade the software is similar to install the software:

# RPM – Uvh foo – 2.0 – l.i 386 RPM

foo# # # # # # # # # # # # # # # # # # # #

user note: RPM will automatically install the old version of the corresponding software package. Rpmsave

saving /etc/foo.conf as /etc/foo.conf.rpmsave

so that the user can manually change the configuration file. In addition, if the user wants to install the older version of the software, the user will see the following error message:

# rpm-uvh foo-1.0-l.i386. RPM

foo packag foo-2.0-l(which is newer) is already installed

error: foo-1.0l-l.i 386. RPM cannot be installed

.
user can use rpm-q to query the corresponding software in the RPM database, RPM will give the name of the software package, version, release version number, for example:

# rpm-q foo

foo-2.0-l

the following is the query can use the specific parameters:
-a query the current system installed all software packages.
-f filename query includes ga file packages.
– F with the -f parameter, just input is standard input (for example the find/usr/bin | RPM – qF)
– q package name:
– q query the package with the -p parameter, just input is standard input (for example the find/MNT/cdrom/RedHat/RPMS | RPM – qQ)
here is the format of the output options:
– I displays the name of the package, description, distribution, size, date of compilation, the date of installation, developers and other information.
-l display the files contained in the software package
-s display the current status of the files contained in the software package, only two states: normal and missing
-d display the documents in the software package (such as man,info,README, etc.)
-c display the configuration files in the software package, these files generally need to be manually modified by the user after installation, for example: Sendmail. Cf, passwd, inittab etc.
if using the -v parameter can be similar to the output of the ls -l

5) in the RPM packages
users can use the RPM used to check the package has been installed, the RPM can check file size, MD5 check code, file permissions, type, and the information such as owner.
here is the parameter description:
– a simple calibration software package if the file exists
– b check package in a single file

– c check installation of all packages – d compare a source package and already installed packages

if the test through, there is no any error messages, if there is an error message, its format is as follows: the error information is one of the eight string, if it is a “. “, means there is no problem, here is the meaning of the corresponding characters: MD5 check error
5 MD5 check error
S file size error
L symbolic connection
T file modification time error
D device file error
U user name error
G group name error
M attributes (including overwrite weight and file type) error
if the user sees this information, it is best to reinstall or manually repair.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

the RPM practical skills!
1) users can install packages via FTP. If users will be able to connect on the network, want to install a new software package, you can directly use it to install to the URL:
for example: under ftp.linuxsir.com/pub/linux/redhat/RPMS/ now have this file package: foo – 1.0-1. I386 RPM, then you can use this command:

# RPM -i ftp.linuxsir.com/pub/linux/redhat/RPMS/foo-1.0-1.i386.rpm

to install, also can query!

2) if the user accidentally wushan several files, but not sure whether those documents, want to check to the whole system, in order to understand which parts may be damaged, you can use:

# RPM – Va

3) if the user meets a person not to come out of the file, want to know it belongs to the words of a software package, you can do it:

# rpb-qf /usr/X11R6/bin/xjewel

results are obtained with the following information:
xjewel-1.6-1

4) if the user gets a new RPM file, but does not know its contents; Or to find out which files a particular file package will install on your system, do this:

gvim: GConf-WARNING **: Client failed to connect to the D-BUS daemon

64-bit Debian GNU/Linux 8.2.0
# gvim mount
(gvim:1657): gnomeUI-WARNING **:When connecting to the session manager:
The specified authentication protocol is not supported.
(gvim:1657): GConf-WARNING **:Client failed to connect to the D-BUS daemon:
No reply received. Possible causes include:remote application not sending reply, message bus security policy blocking reply, reply timeout, or network connection disruption.
Solution:Use the “soo–” command to get the root identity.