Tag Archives: Cents7

[Solved] error: ‘IEEE80211_BAND_2GHZ’ undeclared here (not in a function)

Environmental description

System: centos7 linux-3.10 0 kernel

Driver version: 00014996-rtl8192eu_linux_v5. 6.3. 1_34030_COEX20171113-0047.20190613.zip

Network card: Realtek rtl8192eu

Problem log

rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/include/../os_dep/linux/ioctl_cfg80211.h:414:27: error: ‘IEEE80211_BAND_2GHZ’ undeclared here (not in a function)
 #define NL80211_BAND_2GHZ IEEE80211_BAND_2GHZ
                           ^

Solution:

Modify IOCTL_cfg80211.h

 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 26)) && (LINUX_VERSION_CODE < KERNEL_VERSION(4, 7, 0))
+#define IEEE80211_BAND_2GHZ 0 //add by wellnw 20211213
 #define NL80211_BAND_2GHZ IEEE80211_BAND_2GHZ
 #define NL80211_BAND_5GHZ IEEE80211_BAND_5GHZ
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0))

[Solved] ioctl_cfg80211.c:1130:4: error: too many arguments to function ‘cfg80211_roamed’

Environmental description

System: centos7 (3.10.0)

Driver version: 00014996-rtl8192eu_linux_v5.6.3.1_34030_COEX20171113-0047.20190613.zip

Network card: Realtek rtl8192eu

Error log

In file included from /home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/include/osdep_service_linux.h:93:0,
                 from /home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/include/osdep_service.h:50,
                 from /home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/include/drv_types.h:27,
                 from /home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:17:
include/net/cfg80211.h:5502:6: note: expected ‘gfp_t’ but argument is of type ‘unsigned char *’
 void cfg80211_roamed(struct net_device *dev, struct cfg80211_roam_info *info,
      ^
/home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1130:4: error: too many arguments to function ‘cfg80211_roamed’
    , GFP_ATOMIC);
    ^

Solution:

Modify IOCTL_cfg80211.C Documents

@@ -1036,7 +1046,7 @@
 #ifdef CONFIG_P2P
 	struct wifidirect_info *pwdinfo = &(padapter->wdinfo);
 #endif
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0) //change by wellnw 20211213
 	struct cfg80211_roam_info roam_info ={};
 #endif
 
@@ -1109,7 +1119,7 @@
 		notify_channel = ieee80211_get_channel(wiphy, freq);
 		#endif
 
-		#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
+		#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0) //change by wellnw 20211213
 		roam_info.bssid = cur_network->network.MacAddress;
 		roam_info.req_ie = pmlmepriv->assoc_req + sizeof(struct rtw_ieee80211_hdr_3addr) + 2;
 		roam_info.req_ie_len = pmlmepriv->assoc_req_len - sizeof(struct rtw_ieee80211_hdr_3addr) - 2;

[Solved] ioctl_cfg80211.c:1141:45: error: ‘struct wireless_dev’ has no member named ‘sme_state’

Environmental description

System: centos7 (3.10.0)

Driver version: 00014996-rtl8192eu_linux_v5.6.3.1_34030_COEX20171113-0047.20190613.zip

Network card: Realtek rtl8192eu

Error log

rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1141:45: error: ‘struct wireless_dev’ has no member named ‘sme_state’
   RTW_INFO("pwdev->sme_state(b)=%d\n", pwdev->sme_state);
                                             ^

rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1152:45: error: ‘struct wireless_dev’ has no member named ‘sme_state’
   RTW_INFO("pwdev->sme_state(a)=%d\n", pwdev->sme_state);
                                             ^

rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1207:45: error: ‘struct wireless_dev’ has no member named ‘sme_state’
   RTW_INFO("pwdev->sme_state(b)=%d\n", pwdev->sme_state);
                                             ^

/home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1209:12: error: ‘struct wireless_dev’ has no member named ‘sme_state’
   if (pwdev->sme_state == CFG80211_SME_CONNECTING) {
            ^
/home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1209:27: error: ‘CFG80211_SME_CONNECTING’ undeclared (first use in this function)
   if (pwdev->sme_state == CFG80211_SME_CONNECTING) {
                           ^
/home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1213:19: error: ‘struct wireless_dev’ has no member named ‘sme_state’
   } else if (pwdev->sme_state == CFG80211_SME_CONNECTED) {
                   ^
/home/w1206/RTL8192EU_linux_v5.6.3.1_34030_COEX20171113-0047.20190613/driver/rtl8192EU_WiFi_linux_v5.6.3.1_34030.20190613_COEX20171113-0047/os_dep/linux/ioctl_cfg80211.c:1213:34: error: ‘CFG80211_SME_CONNECTED’ undeclared (first use in this function)
   } else if (pwdev->sme_state == CFG80211_SME_CONNECTED) {
                                  ^

Solution:

Modify IOCTL_cfg80211.c

 	} else {
-		#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 11, 0) || defined(COMPAT_KERNEL_RELEASE)
+		#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0) || defined(COMPAT_KERNEL_RELEASE) //change by wellnw 20211213
 		RTW_INFO("pwdev->sme_state(b)=%d\n", pwdev->sme_state);
 		#endif
 
@@ -1148,7 +1158,7 @@
 				, pmlmepriv->assoc_rsp + sizeof(struct rtw_ieee80211_hdr_3addr) + 6
 				, pmlmepriv->assoc_rsp_len - sizeof(struct rtw_ieee80211_hdr_3addr) - 6
 				, WLAN_STATUS_SUCCESS, GFP_ATOMIC);
-		#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 11, 0) || defined(COMPAT_KERNEL_RELEASE)
+		#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0) || defined(COMPAT_KERNEL_RELEASE)//change by wellnw 20211213
 		RTW_INFO("pwdev->sme_state(a)=%d\n", pwdev->sme_state);
 		#endif
 	}
@@ -1203,7 +1213,7 @@
 	_enter_critical_bh(&pwdev_priv->connect_req_lock, &irqL);
 
 	if (padapter->ndev_unregistering || !rtw_wdev_not_indic_disco(pwdev_priv)) {
-		#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 11, 0) || defined(COMPAT_KERNEL_RELEASE)
+		#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0) || defined(COMPAT_KERNEL_RELEASE)//change by wellnw 20211213
 		RTW_INFO("pwdev->sme_state(b)=%d\n", pwdev->sme_state);
 
 		if (pwdev->sme_state == CFG80211_SME_CONNECTING) {
@@ -1217,6 +1227,7 @@

Robo3T Remote Connect MongoDB Error: Failed to refresh ‘Collections‘. Error: ListCollections failed

First, set up the remote connection of Mongo server:

vim  /usr/local/mongodb/etc/mongodb.conf

Note out:

bindIp: 127.0.0.1  # Listen to local interface only, comment to listen on all interfaces.

The binding IP is 127.0.0.1 by default. Only local connections are allowed

bind_ip = 0.0.0.0

Restart Mongo remote connection:

service mongod restart

Robo3T reports error connecting to remote MongoDB: Failed to refresh ‘Collections’. Error: ListCollections failed:
Possible version issue.
Robo 3T 1.4 -> MongoDB 4.2
Robo 3T 1.3 -> MongoDB 4.0
Robo 3T 1.1 -> MongoDB 3.4
Robo 3T 0.9 -> MongoDB 3.2
Robo 3T 0.8.x -> MongoDB 2.4.0
Download the corresponding version.
https://github.com/Studio3T/robomongo/releases/tag/v1.3.1

[Solved] Error reported using telnet command in Centos7: telnet: error while loading shared libraries: libtinfo.so.6

1.Preconditions for solution

LZ found the package libtinfo. So. 5 in the directory/usr/lib64. Although there is no libtinfo. So. 6, there is libtinfo. So. 5, which can be downward compatible. Building a link can solve this problem.

2.Solutions

1. Replace the nonexistent libtinfo. So. 6 library with libtinfo. So. 5 and execute the following command

[root@localhost /]# cd /usr/lib64/
[root@localhost lib64]# ln -s libtinfo.so.5 libtinfo.so.6

2. Execute the telnet command again.

Error 1045 (28000): access denied for user ‘root’ @’localhost ‘(using password: no)

Error 1045 (28000): access denied for user ‘root’ @’localhost ‘(using password: no)

The solution steps are as follows:

1. First stop the database service: systemctl stop mariadb.service

2. Use mysqld_ Safe to start mysqld server: mysqld_ safe –user=mysql –skip-grant-tables –skip-networking &

Display: exit Ctrl + C

3. Login: MySQL – U root mysql

4. Modify the password of the root user: update user set password = password (‘newpassword ‘) where user’s root’;

5. Use the modified root user and new password to log in to the database: MySQL – uroot – P

 

The MariaDB server is running with the –skip-grant-tables option so it cannot execute this statement

An error occurred when creating a user. The execution statement is:

GRANT ALL PRIVILEGES ON *.* TO helei IDENTIFIED BY ‘MANAGER’ WITH GRANT OPTION;

Solution: MySQL & gt; flush privileges;

Reference: MariaDB initial login error 1045 (28000) solution

https://blog.csdn.net/carry9148/article/details/52252780

Error: nothing to do in centos7’s Yum installation

catalog

Caption:

Yum installation error description:

Solution, update Yum source:

Re install, problem solved:


 

Caption:

After installing centos7, sometimes Yum is not up-to-date. It’s better to update the yum source after installing the system. Since the yum source was not updated after installing the operating system, the following error occurred today.

Yum installation error description:

 

Solution, update Yum source:

yum -y update 

 

Re install, problem solved: