ubuntu14.04.1启动mysql出错

ubuntu版本为14.04.1,apt-get install mysql 启动出错: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

my.cnf配置如下:
#

The MySQL database server configuration file.

#

You can copy this to one of:

- "/etc/mysql/my.cnf" to set global options,

- "~/.my.cnf" to set user-specific options.

One can use all long options that the program supports.

Run program with --help to get a list of available options and with

--print-defaults to see which it would actually understand and use.

#

For explanations see

http://dev.mysql.com/doc/mysql/en/server-system-variables.html

This will be passed to all mysql clients

It has been reported that passwords should be enclosed with ticks/quotes

escpecially if they contain "#" chars...

Remember to edit /etc/mysql/debian.cnf when changing the socket location.

[client]
port = 3306
socket = /var/run/mysqld/mysqld.sock

Here is entries for some specific programs

The following values assume you have at least 32M ram

This was formally known as [safe_mysqld]. Both versions are currently parsed.

[mysqld_safe]
socket = /var/run/mysqld/mysqld.sock
nice = 0

[mysqld]
#

* Basic Settings

#
user = mysql
pid-file = /var/run/mysqld/mysqld.pid
socket = /var/run/mysqld/mysqld.sock
port = 3306
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
lc-messages-dir = /usr/share/mysql
skip-external-locking
#

Instead of skip-networking the default is now to listen only on

localhost which is more compatible and is not less secure.

bind-address = 127.0.0.1
#

* Fine Tuning

#
key_buffer = 16M
max_allowed_packet = 16M
thread_stack = 192K
thread_cache_size = 8

This replaces the startup script and checks MyISAM tables if needed

the first time they are touched

myisam-recover = BACKUP
#max_connections = 100
#table_cache = 64
#thread_concurrency = 10
#

* Query Cache Configuration

#
query_cache_limit = 1M
query_cache_size = 16M
#

* Logging and Replication

#

Both location gets rotated by the cronjob.

Be aware that this log type is a performance killer.

As of 5.1 you can enable the log at runtime!

#general_log_file = /var/log/mysql/mysql.log
#general_log = 1
#

Error log - should be very few entries.

#
log_error = /var/log/mysql/error.log
#

Here you can see queries with especially long duration

#log_slow_queries = /var/log/mysql/mysql-slow.log
#long_query_time = 2
#log-queries-not-using-indexes
#

The following can be used as easy to replay backup logs or for replication.

note: if you are setting up a replication slave, see README.Debian about

other settings you may need to change.

#server-id = 1
#log_bin = /var/log/mysql/mysql-bin.log
expire_logs_days = 10
max_binlog_size = 100M
#binlog_do_db = include_database_name
#binlog_ignore_db = include_database_name
#

* InnoDB

#

InnoDB is enabled by default with a 10MB datafile in /var/lib/mysql/.

Read the manual for more InnoDB related options. There are many!

#

* Security Features

#

Read the manual, too, if you want chroot!

chroot = /var/lib/mysql/

#

For generating SSL certificates I recommend the OpenSSL GUI "tinyca".

#

ssl-ca=/etc/mysql/cacert.pem

ssl-cert=/etc/mysql/server-cert.pem

ssl-key=/etc/mysql/server-key.pem

[mysqldump]
quick
quote-names
max_allowed_packet = 16M

[mysql]
#no-auto-rehash # faster start of mysql but no tab completition

[isamchk]
key_buffer = 16M

#

* IMPORTANT: Additional settings that can override those from this file!

The files must end with '.cnf', otherwise they'll be ignored.

#
!includedir /etc/mysql/conf.d/

在/var/run/mysqld/中没有任何文件,/var/lib/mysql/下为
debian-5.5.flag ibdata1 ib_logfile0 ib_logfile1 mysql performance_schema
找不到mysqld.sock文件。

1个回答

需要root权限

 sudo apt-get install mysql
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
MySQL for Ubuntu服务无法启动

在Ubuntu系统下安装MySQL成功后,修改默认的配置文件my.cnf,比如添加默认字符集设置等,就无法启动MySQL服务,启动时的错误信息:Starting MySQL.... * The server quit without updating PID file (/usr/local/mysql/data/linx-pc.pid).请大神看下是什么原因造成的?

Ubuntu安装Mysql启动出错

小弟刚刚接触Linux,想安装一个mysql,按照这个步骤尝试安装[http://jingyan.baidu.com/article/4f7d5712d5f8181a2019270e.html](http://jingyan.baidu.com/article/4f7d5712d5f8181a2019270e.html ""),结果最后服务启动不了。 输入systemctl status mysql.service命令查看的时候显示 mysql.service - MySQL Community Server Loaded: loaded (/lib/systemd/system/mysql.service; disabled; vendor preset: enabled) Active: deactivating (final-sigterm) (Result: exit-code) Process: 17564 ExecStart=/usr/sbin/mysqld --daemonize --pid-file=/var/run/mysqld/mysqld.pid (code=exited, status=1/FAILURE) CGroup: /system.slice/mysql.service └─17566 /usr/sbin/mysqld --daemonize --pid-file=/var/run/mysqld/my... Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.520393Z 0 [Note] ...d. Nov 20 06:51:35 ubuntu mysqld[17564]: mysqld: Table 'mysql.plugin' doesn't exist Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.520736Z 0 [ERROR]...t. Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.521871Z 0 [Warnin...d. Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.522009Z 0 [Warnin...ey Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.523079Z 0 [Note] ...06 Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.523154Z 0 [Note] ...e. Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.523182Z 0 [Note] ...'; Nov 20 06:51:35 ubuntu mysqld[17564]: 2016-11-20T14:51:35.523352Z 0 [Note] ...'. Nov 20 06:51:35 ubuntu systemd[1]: mysql.service: Control process exited, c...=1 Hint: Some lines were ellipsized, use -l to show in full. 输入journalctl -xe命令显示 -- Subject: Unit mysql.service has finished shutting down -- Defined-By: systemd -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel -- -- Unit mysql.service has finished shutting down. Nov 20 07:10:32 ubuntu systemd[1]: Starting MySQL Community Server... -- Subject: Unit mysql.service has begun start-up -- Defined-By: systemd -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel -- -- Unit mysql.service has begun starting up. Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.122479Z 0 [Warning] TI Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.124201Z 0 [Note] /usr/ Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.127834Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.127858Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.127864Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.127869Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.127874Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.127879Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.128131Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.128221Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.129445Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.139914Z 0 [Note] InnoD Nov 20 07:10:33 ubuntu mysqld[32270]: 2016-11-20T15:10:33.141532Z 0 [Note] InnoD 请各位大牛帮忙看看怎么回事,不胜感激!

Ubuntu16.04 修改mysql 数据存储目录datadir 启动失败

Ubuntu16.04 修改mysql 数据存储目录datadir 启动失败 ,网上的各种方法都已经尝试,但是还是没有启动成功请教各位大神!!!!! 修改步骤 ## 创建 迁移文件夹 > cd /mnt > mkdir lib > cd lib && mkdir mysqldata > 数据存放在 /mnt/lib/mysqldata 修改所属用户 和所属用户组为 msyql > sudo chown -vR mysql:mysql /mnt/lib/mysqldata 修改权限 > sudo chmod -vR 700 /mnt/lib/mysqldata ### 迁移文件 停止服务 > sudo /etc/init.d/mysql stop 迁移数据 > cp -av /var/lib/mysql/* /mnt/lib/mysqldata # vim /etc/mysql/mysql.conf.d/mysqld.cnf 将 [mysqld] 组下的 datadir改为: datadir = /mnt/lib/mysqldata sudo vim /etc/apparmor.d/usr.sbin.mysqld 找到其中的 /var/lib/mysql/ r, /var/lib/mysql/** rwk, 两行权限声明,可以在前面加上#好注释掉。然后对照格式,加入新路径的权限声明: /mnt/lib/mysqldata/ r, /mnt/lib/mysqldata/** rwk 重启服务 配置文件修改成功后就可以重启数据库,重启数据库之前需要先重新载入apparmor配置文件,使用下面命令重新载入: > sudo /etc/init.d/apparmor restart >sudo /etc/init.d/mysql start 重启的时候 Starting mysql (via systemctl): mysql.serviceJob for mysql.service failed because the control process exited with error code. See "systemctl status mysql.service" and "journalctl -xe" for details. failed! root@iZm5e472vz1trxejt8m5akZ:/etc/mysql# systemctl status mysql.service ● mysql.service - MySQL Community Server Loaded: loaded (/lib/systemd/system/mysql.service; enabled; vendor preset: enabled) Active: active (running) since Sat 2018-06-23 00:55:37 CST; 25s ago Process: 13418 ExecStartPost=/usr/share/mysql/mysql-systemd-start post (code=exited, status=0/SUCCESS) Process: 13408 ExecStartPre=/usr/share/mysql/mysql-systemd-start pre (code=exited, status=0/SUCCESS) Main PID: 13417 (mysqld) CGroup: /system.slice/mysql.service └─13417 /usr/sbin/mysqld . 配置文件 内容 ``` # # The MySQL database server configuration file. # # You can copy this to one of: # - "/etc/mysql/my.cnf" to set global options, # - "~/.my.cnf" to set user-specific options. # # One can use all long options that the program supports. # Run program with --help to get a list of available options and with # --print-defaults to see which it would actually understand and use. # # For explanations see # http://dev.mysql.com/doc/mysql/en/server-system-variables.html # This will be passed to all mysql clients # It has been reported that passwords should be enclosed with ticks/quotes # escpecially if they contain "#" chars... # Remember to edit /etc/mysql/debian.cnf when changing the socket location. # Here is entries for some specific programs # The following values assume you have at least 32M ram [mysqld_safe] socket = /var/run/mysqld/mysqld.sock nice = 0 [mysqld] # # * Basic Settings # user = mysql pid-file = /var/run/mysqld/mysqld.pid socket = /var/run/mysqld/mysqld.sock port = 3306 basedir = /usr # datadir = /var/lib/mysql datadir = /mnt/lib/mysqldata tmpdir = /tmp lc-messages-dir = /usr/share/mysql skip-external-locking # # Instead of skip-networking the default is now to listen only on # localhost which is more compatible and is not less secure. bind-address = 0.0.0.0 # # * Fine Tuning # key_buffer_size = 16M max_allowed_packet = 16M thread_stack = 192K thread_cache_size = 8 # This replaces the startup script and checks MyISAM tables if needed # the first time they are touched myisam-recover-options = BACKUP #max_connections = 100 #table_cache = 64 #thread_concurrency = 10 # # * Query Cache Configuration # query_cache_limit = 1M query_cache_size = 16M # # * Logging and Replication # # Both location gets rotated by the cronjob. # Be aware that this log type is a performance killer. # As of 5.1 you can enable the log at runtime! #general_log_file = /var/log/mysql/mysql.log #general_log = 1 # # Error log - should be very few entries. # log_error = /var/log/mysql/error.log # # Here you can see queries with especially long duration #log_slow_queries = /var/log/mysql/mysql-slow.log #long_query_time = 2 #log-queries-not-using-indexes # # The following can be used as easy to replay backup logs or for replication. # note: if you are setting up a replication slave, see README.Debian about # other settings you may need to change. #server-id = 1 #log_bin = /var/log/mysql/mysql-bin.log expire_logs_days = 10 max_binlog_size = 100M #binlog_do_db = include_database_name #binlog_ignore_db = include_database_name # # * InnoDB # # InnoDB is enabled by default with a 10MB datafile in /var/lib/mysql/. # Read the manual for more InnoDB related options. There are many! # # * Security Features # # Read the manual, too, if you want chroot! # chroot = /var/lib/mysql/ # # For generating SSL certificates I recommend the OpenSSL GUI "tinyca". # # ssl-ca=/etc/mysql/cacert.pem # ssl-cert=/etc/mysql/server-cert.pem # ssl-key=/etc/mysql/server-key.pem ```

ubuntu 16.04安装mysql,初始化数据库报错。

系统:阿里云 Ubuntu16.4 ,64位 mysql:5.7.17 问题描述: 使用官网64位tar.gz压缩包进行mysql安装。压缩包解压后,进行数据库初始化。 (5.7.17版本没有data目录,需要自己创建;mysql_install_db 文件在bin目录下, scripts目录取消) 执行命令: bin/mysql_install_db --user=mysql --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data 报错:如图 ![图片说明](https://img-ask.csdn.net/upload/201701/16/1484537699_845096.png) 这个问题困扰了我2天了。。。。网上好的的教程,都试过了,尴尬。。。请教大神指点 //=========================================== 更新。 现在我按照mysql官网文档进行安装,又出现问题了。

ubuntu 关闭/启动mysql提示:Rejected send message,

系统:ubuntu 使用命令:service mysql stop 提示错误信息: stop: Rejected send message, 1 matched rules; type="method_call", sender=":1.12" (uid=1003 pid=5082 comm="stop mysql ") interface="com.ubuntu.Upstart0_6.Job" member="Stop" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init ") 使用命令:service mysql start 提示错误信息: start: Rejected send message, 1 matched rules; type="method_call", sender=":1.14" (uid=1003 pid=5089 comm="start mysql ") interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init ")

在win10子系统ubuntu18.04下安装mysql5.7尝试重新启动的时候出现以下报错

在win10子系统ubuntu18.04下安装mysql5.7尝试重新启动的时候出现以下报错 1.安装mysql-server ``` root@PC-5200:/home/tom# apt-get -y install mysql-server ``` ``` Reading package lists... Done Building dependency tree Reading state information... Done The following package was automatically installed and is no longer required: libfreetype6 Use 'apt autoremove' to remove it. The following additional packages will be installed: libaio1 libcgi-fast-perl libcgi-pm-perl libencode-locale-perl libevent-core-2.1-6 libfcgi-perl libhtml-parser-perl libhtml-tagset-perl libhtml-template-perl libhttp-date-perl libhttp-message-perl libio-html-perl liblwp-mediatypes-perl libssl1.1 libtimedate-perl liburi-perl mysql-client-5.7 mysql-client-core-5.7 mysql-common mysql-server-5.7 mysql-server-core-5.7 Suggested packages: libdata-dump-perl libipc-sharedcache-perl libwww-perl mailx tinyca The following NEW packages will be installed: libaio1 libcgi-fast-perl libcgi-pm-perl libencode-locale-perl libevent-core-2.1-6 libfcgi-perl libhtml-parser-perl libhtml-tagset-perl libhtml-template-perl libhttp-date-perl libhttp-message-perl libio-html-perl liblwp-mediatypes-perl libtimedate-perl liburi-perl mysql-client-5.7 mysql-client-core-5.7 mysql-common mysql-server mysql-server-5.7 mysql-server-core-5.7 The following packages will be upgraded: libssl1.1 1 upgraded, 21 newly installed, 0 to remove and 136 not upgraded. Need to get 21.0 MB of archives. After this operation, 157 MB of additional disk space will be used. Get:1 http://mirrors.aliyun.com/ubuntu bionic/main amd64 mysql-common all 5.8+1.0.4 [7308 B] Get:2 http://mirrors.aliyun.com/ubuntu bionic-updates/main amd64 libaio1 amd64 0.3.110-5ubuntu0.1 [6476 B] Get:3 http://mirrors.aliyun.com/ubuntu bionic-security/main amd64 libssl1.1 amd64 1.1.1-1ubuntu2.1~18.04.5 [1300 kB] Get:4 http://mirrors.aliyun.com/ubuntu bionic-security/main amd64 mysql-client-core-5.7 amd64 5.7.28-0ubuntu0.18.04.4 [6644 kB] Get:5 http://mirrors.aliyun.com/ubuntu bionic-security/main amd64 mysql-client-5.7 amd64 5.7.28-0ubuntu0.18.04.4 [1943 kB] Get:6 http://mirrors.aliyun.com/ubuntu bionic-security/main amd64 mysql-server-core-5.7 amd64 5.7.28-0ubuntu0.18.04.4 [7432 kB] Get:7 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libevent-core-2.1-6 amd64 2.1.8-stable-4build1 [85.9 kB] Get:8 http://mirrors.aliyun.com/ubuntu bionic-security/main amd64 mysql-server-5.7 amd64 5.7.28-0ubuntu0.18.04.4 [2932 kB] Get:9 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libhtml-tagset-perl all 3.20-3 [12.1 kB] Get:10 http://mirrors.aliyun.com/ubuntu bionic/main amd64 liburi-perl all 1.73-1 [77.2 kB] Get:11 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libhtml-parser-perl amd64 3.72-3build1 [85.9 kB] Get:12 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libcgi-pm-perl all 4.38-1 [185 kB] Get:13 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libfcgi-perl amd64 0.78-2build1 [32.8 kB] Get:14 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libcgi-fast-perl all 1:2.13-1 [9940 B] Get:15 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libencode-locale-perl all 1.05-1 [12.3 kB] Get:16 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libhtml-template-perl all 2.97-1 [59.0 kB] Get:17 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libtimedate-perl all 2.3000-2 [37.5 kB] Get:18 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libhttp-date-perl all 6.02-1 [10.4 kB] Get:19 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libio-html-perl all 1.001-1 [14.9 kB] Get:20 http://mirrors.aliyun.com/ubuntu bionic/main amd64 liblwp-mediatypes-perl all 6.02-1 [21.7 kB] Get:21 http://mirrors.aliyun.com/ubuntu bionic/main amd64 libhttp-message-perl all 6.14-1 [72.1 kB] Get:22 http://mirrors.aliyun.com/ubuntu bionic-security/main amd64 mysql-server all 5.7.28-0ubuntu0.18.04.4 [9940 B] Fetched 21.0 MB in 9s (2376 kB/s) Preconfiguring packages ... Selecting previously unselected package mysql-common. (Reading database ... 28663 files and directories currently installed.) Preparing to unpack .../0-mysql-common_5.8+1.0.4_all.deb ... Unpacking mysql-common (5.8+1.0.4) ... Selecting previously unselected package libaio1:amd64. Preparing to unpack .../1-libaio1_0.3.110-5ubuntu0.1_amd64.deb ... Unpacking libaio1:amd64 (0.3.110-5ubuntu0.1) ... Preparing to unpack .../2-libssl1.1_1.1.1-1ubuntu2.1~18.04.5_amd64.deb ... Unpacking libssl1.1:amd64 (1.1.1-1ubuntu2.1~18.04.5) over (1.1.0g-2ubuntu4.3) ... Selecting previously unselected package mysql-client-core-5.7. Preparing to unpack .../3-mysql-client-core-5.7_5.7.28-0ubuntu0.18.04.4_amd64.deb ... Unpacking mysql-client-core-5.7 (5.7.28-0ubuntu0.18.04.4) ... Selecting previously unselected package mysql-client-5.7. Preparing to unpack .../4-mysql-client-5.7_5.7.28-0ubuntu0.18.04.4_amd64.deb ... Unpacking mysql-client-5.7 (5.7.28-0ubuntu0.18.04.4) ... Selecting previously unselected package mysql-server-core-5.7. Preparing to unpack .../5-mysql-server-core-5.7_5.7.28-0ubuntu0.18.04.4_amd64.deb ... Unpacking mysql-server-core-5.7 (5.7.28-0ubuntu0.18.04.4) ... Selecting previously unselected package libevent-core-2.1-6:amd64. Preparing to unpack .../6-libevent-core-2.1-6_2.1.8-stable-4build1_amd64.deb ... Unpacking libevent-core-2.1-6:amd64 (2.1.8-stable-4build1) ... Setting up mysql-common (5.8+1.0.4) ... update-alternatives: using /etc/mysql/my.cnf.fallback to provide /etc/mysql/my.cnf (my.cnf) in auto mode Selecting previously unselected package mysql-server-5.7. (Reading database ... 28832 files and directories currently installed.) Preparing to unpack .../00-mysql-server-5.7_5.7.28-0ubuntu0.18.04.4_amd64.deb ... Unpacking mysql-server-5.7 (5.7.28-0ubuntu0.18.04.4) ... Selecting previously unselected package libhtml-tagset-perl. Preparing to unpack .../01-libhtml-tagset-perl_3.20-3_all.deb ... Unpacking libhtml-tagset-perl (3.20-3) ... Selecting previously unselected package liburi-perl. Preparing to unpack .../02-liburi-perl_1.73-1_all.deb ... Unpacking liburi-perl (1.73-1) ... Selecting previously unselected package libhtml-parser-perl. Preparing to unpack .../03-libhtml-parser-perl_3.72-3build1_amd64.deb ... Unpacking libhtml-parser-perl (3.72-3build1) ... Selecting previously unselected package libcgi-pm-perl. Preparing to unpack .../04-libcgi-pm-perl_4.38-1_all.deb ... Unpacking libcgi-pm-perl (4.38-1) ... Selecting previously unselected package libfcgi-perl. Preparing to unpack .../05-libfcgi-perl_0.78-2build1_amd64.deb ... Unpacking libfcgi-perl (0.78-2build1) ... Selecting previously unselected package libcgi-fast-perl. Preparing to unpack .../06-libcgi-fast-perl_1%3a2.13-1_all.deb ... Unpacking libcgi-fast-perl (1:2.13-1) ... Selecting previously unselected package libencode-locale-perl. Preparing to unpack .../07-libencode-locale-perl_1.05-1_all.deb ... Unpacking libencode-locale-perl (1.05-1) ... Selecting previously unselected package libhtml-template-perl. Preparing to unpack .../08-libhtml-template-perl_2.97-1_all.deb ... Unpacking libhtml-template-perl (2.97-1) ... Selecting previously unselected package libtimedate-perl. Preparing to unpack .../09-libtimedate-perl_2.3000-2_all.deb ... Unpacking libtimedate-perl (2.3000-2) ... Selecting previously unselected package libhttp-date-perl. Preparing to unpack .../10-libhttp-date-perl_6.02-1_all.deb ... Unpacking libhttp-date-perl (6.02-1) ... Selecting previously unselected package libio-html-perl. Preparing to unpack .../11-libio-html-perl_1.001-1_all.deb ... Unpacking libio-html-perl (1.001-1) ... Selecting previously unselected package liblwp-mediatypes-perl. Preparing to unpack .../12-liblwp-mediatypes-perl_6.02-1_all.deb ... Unpacking liblwp-mediatypes-perl (6.02-1) ... Selecting previously unselected package libhttp-message-perl. Preparing to unpack .../13-libhttp-message-perl_6.14-1_all.deb ... Unpacking libhttp-message-perl (6.14-1) ... Selecting previously unselected package mysql-server. Preparing to unpack .../14-mysql-server_5.7.28-0ubuntu0.18.04.4_all.deb ... Unpacking mysql-server (5.7.28-0ubuntu0.18.04.4) ... Setting up libhtml-tagset-perl (3.20-3) ... Setting up libevent-core-2.1-6:amd64 (2.1.8-stable-4build1) ... Processing triggers for ureadahead (0.100.0-21) ... Setting up libencode-locale-perl (1.05-1) ... Setting up libtimedate-perl (2.3000-2) ... Setting up libio-html-perl (1.001-1) ... Setting up liblwp-mediatypes-perl (6.02-1) ... Processing triggers for libc-bin (2.27-3ubuntu1) ... Setting up libaio1:amd64 (0.3.110-5ubuntu0.1) ... Setting up liburi-perl (1.73-1) ... Setting up libssl1.1:amd64 (1.1.1-1ubuntu2.1~18.04.5) ... Checking for services that may need to be restarted...done. Checking for services that may need to be restarted...done. Checking init scripts... Restarting services possibly affected by the upgrade: invoke-rc.d: could not determine current runlevel Services restarted successfully. Processing triggers for systemd (237-3ubuntu10.21) ... Setting up libhtml-parser-perl (3.72-3build1) ... Setting up libcgi-pm-perl (4.38-1) ... Processing triggers for man-db (2.8.3-2ubuntu0.1) ... Setting up mysql-client-core-5.7 (5.7.28-0ubuntu0.18.04.4) ... Setting up libfcgi-perl (0.78-2build1) ... Setting up libhttp-date-perl (6.02-1) ... Setting up libhtml-template-perl (2.97-1) ... Setting up mysql-server-core-5.7 (5.7.28-0ubuntu0.18.04.4) ... Setting up libcgi-fast-perl (1:2.13-1) ... Setting up libhttp-message-perl (6.14-1) ... Setting up mysql-client-5.7 (5.7.28-0ubuntu0.18.04.4) ... Setting up mysql-server-5.7 (5.7.28-0ubuntu0.18.04.4) ... invoke-rc.d: could not determine current runlevel * Stopping MySQL database server mysqld [ OK ] update-alternatives: using /etc/mysql/mysql.cnf to provide /etc/mysql/my.cnf (my.cnf) in auto mode Renaming removed key_buffer and myisam-recover options (if present) Cannot open /proc/net/unix: No such file or directory Cannot stat file /proc/1/fd/5: Operation not permitted Cannot stat file /proc/1/fd/10: Operation not permitted Cannot stat file /proc/1/fd/6: Operation not permitted Cannot stat file /proc/7/fd/7: Operation not permitted Cannot stat file /proc/7/fd/10: Operation not permitted Cannot stat file /proc/7/fd/5: Operation not permitted Created symlink /etc/systemd/system/multi-user.target.wants/mysql.service → /lib/systemd/system/mysql.service. invoke-rc.d: could not determine current runlevel Setting up mysql-server (5.7.28-0ubuntu0.18.04.4) ... Processing triggers for libc-bin (2.27-3ubuntu1) ... Processing triggers for ureadahead (0.100.0-21) ... Processing triggers for systemd (237-3ubuntu10.21) ... ``` 2.启动mysql服务 ``` root@PC-5200:/home/tom# systemctl start mysql.service ``` 3.出现如下报错 ``` System has not been booted with systemd as init system (PID 1). Can't operate. ```

ubuntu14.04安装MySQL5.6各种错,但是直接安装MySQL5.5就好了。

输入命令sudo apt-get install mysql-server-5.6 第一个问题的解决方式:https://help.aliyun.com/knowledge_detail/41124.html ``` 1.Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: mysql-server-5.6 : Depends: mysql-common (>= 5.6.22-1~) but 5.5.58-0ubuntu0.14.04.1 is to be installed E: Unable to correct problems, you have held broken packages. ``` 2. 2017-11-29 07:09:25 0 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead. 2017-11-29 07:09:25 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). 2017-11-29 07:09:25 0 [Note] /usr/sbin/mysqld (mysqld 5.6.33-0ubuntu0.14.04.1) starting as process 9131 ... start: Job failed to start invoke-rc.d: initscript mysql, action "start" failed. dpkg: error processing package mysql-server-5.6 (--configure): subprocess installed post-installation script returned error exit status 1 E: Sub-process /usr/bin/dpkg returned an error code (1) 第一个问题解决了。第二个问题搞了半个下午还是没弄成(我运行的时候根本就sock文件),最好卸载直接装成了5.5的了。

ubuntu下mysql忘记密码

Ubuntu 16.04.1 LTS mysql5.7.17 试过网上很多方法都不行 能够卸载重装或修改密码的方案求大牛抛出

Linux Ubuntu 16.04 ,重启了lampp后,mysql启动不了

今天把Linux下的xampp重启了一下,结果悲催了,mysql启动不了,用netstat -anl查看的时候,3306端口也没有,进程也没产生,所以就想问问各位大佬,有谁遇到过没?怎么解决的? ![图片说明](https://img-ask.csdn.net/upload/201902/21/1550743645_477484.png) ![图片说明](https://img-ask.csdn.net/upload/201902/21/1550743584_375842.png)

ubuntu 16.04安装mysql出现mysql-apt-config错误

root@ssk:~# sudo dpkg -i mysql-apt-config_0.5.3-1_all.deb (Reading database ... 97834 files and directories currently installed.) Preparing to unpack mysql-apt-config_0.5.3-1_all.deb ... Unpacking mysql-apt-config (0.5.3-1) over (0.5.3-1) ... Setting up mysql-apt-config (0.5.3-1) ... dpkg: error processing package mysql-apt-config (--install): subprocess installed post-installation script returned error exit status 10 Errors were encountered while processing: mysql-apt-config

ubuntu上mysql数据库的远程登录

我在Win7系统中想要远程登录虚拟机上的mysql数据库可是一直无法连接 第一次虚拟机上ubuntu系统没有关闭防火墙 提示: ![图片说明](https://img-ask.csdn.net/upload/201506/09/1433836212_395889.png) 后面的是(10060) 第二次我把虚拟机的防火墙卸载了 重新登录 显示 ![图片说明](https://img-ask.csdn.net/upload/201506/09/1433837639_849190.png) 后面是(10061) 这是怎么回事啊 求大神

关于Ubuntu16.04用tar.gz通用压缩包安装mysql5.7.17失败

系统Ubuntu16.04 64位 准备安装MySQL 57.7.17 概要 apt-cache search libaio #安装mysql依赖库 tar -zxvf -zxvf mysql-5.7.17-linux-glibc2.5-x86_64.tar.gz #解压压缩包 mv mysql-5.7.17-linux-glibc2.5-x86_64 mysql #修改名字 groupadd mysql #添加用户组 useradd -r -g mysql -s /bin/false mysql #添加用户 cd mysql #进入mysql目录 mkdir mysql-files #新建目录 chmod 750 mysql-files #给目录授权为mysql 用户 chown -R mysql . chgrp -R mysql . bin/mysqld --initialize --user=mysql --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data #初始化mysql数据库 bin/mysql_ssl_rsa_setup #创建SSL证书,密钥文件和RSA密钥对文件 chown -R root . #给当前目录授权为用户root chown -R mysql data mysql-files bin/mysqld_safe --user=mysql & #启动mysql 问题卡在这了 ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491243943_360085.jpg) 详细步骤 1.安装准备 1.1查看自己的Linux系统版本 命令: cat /etc/issue 再具体点:uname -a 86_64就代表64位的系统 OK,咱们确定了自己的系统,现在去MySQL官网下载二进制压缩包源文件 1.2官网下载安装包 https://dev.mysql.com/downloads/mysql/ ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244259_939400.jpg) 选择对应的安装包 ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244281_48676.jpg) ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244297_258139.jpg) 下载的话,有两种方式: 1.从官网下载,然后用FTP软件上传到服务器上。 2.使用在线下载的方式,使用命令: wget -P /usr/local/support https://cdn.mysql.com//Downloads/MySQL-5.7/mysql-5.7.17-linux-glibc2.5-x86_64.tar.gz 注:-P /usr/local/support 是指定下载目录 不要问我为啥网速这么快。。。。我也震惊了 ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244091_52801.jpg) 2.开始安装: 参考官方文档 ①为了预防以前安装过mysql,导致旧版本遗留文件冲突,所以需要把以前安装的文件都删除掉 /etc/my.cnf /etc/msyql目录 查找命令: find / -name 文件名or目录名 删除命令: rm -rf 文件名or目录名 ②安装mysql的依赖库libaio 搜索命令 apt-cache search libaio apt-cache search libaio 如果搜索没有显示结果,就安装 安装命令:apt-get install libaio1 注:如果报错,则需要使用更新命令 apt-get update 更新后就可以安装依赖库了 ③解压压缩包 命令: tar -zxvf -zxvf mysql-5.7.17-linux-glibc2.5-x86_64.tar.gz ④改名字,便于操作 命令:mv mysql-5.7.17-linux-glibc2.5-x86_64 mysql ④添加用户组, 添加用户 groupadd mysql useradd -r -g mysql -s /bin/false mysql ⑤进入msyql目录,创建目录mysql-files cd mysql mkdir mysql-files ⑥给文件夹授权为用户mysql chmod 750 mysql-files chown -R mysql . chgrp -R mysql . ⑦初始化数据库 bin/mysqld --initialize --user=mysql --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data ⑧创建SSL证书,密钥文件和RSA密钥对文件 bin/mysql_ssl_rsa_setup ⑨给当前目录授权为用户root chown -R root . chown -R mysql data mysql-files ⑩问题来了 每当我执行到这个命令时,就卡那不懂了。。。。请教大神,这是为什么 bin/mysqld_safe --user=mysql & # Next command is optional ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244374_944582.jpg) 然后: 执行 mysql -u root -p 再输入密码,显示: ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244197_897753.png) 尝试解决 网上搜的方法: 在my.cnf 中添加sockt ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244246_429225.png) 使用该方法启动 mysql -p --socket=/tmp/mysql.sock ![图片说明](https://img-ask.csdn.net/upload/201704/04/1491244255_351582.png) 另外,参考这篇博客 http://ng2.site/mysql/2016/11/16/install-mysql-offline.html 也是安装失败,请大神指点! ------------------------------------------------------------------------------------------------------------------------------------------------------ PS: 我用apt-get install mysql-server 可以成功安装,但是用通用二进制压缩包离线安装一直安装不成功,这个问题纠结我很久了,成了心结,所以一定要解决掉!

ubuntu 16.04 下安装mysql 数据库遇到如下问题,求大神帮忙解决

ubuntu 16.04 下安装mysql数据库遇到如下错误: 7月 19 17:24:07 wenyaxin-Lenovo-XiaoXin-310-15IKB systemd[1]: Failed to star... 7月 19 17:24:07 wenyaxin-Lenovo-XiaoXin-310-15IKB systemd[1]: mysql.service:... 7月 19 17:24:07 wenyaxin-Lenovo-XiaoXin-310-15IKB systemd[1]: mysql.service:... Hint: Some lines were ellipsized, use -l to show in full. dpkg: 处理软件包 mysql-server-5.7 (--configure)时出错: 子进程 已安装 post-installation 脚本 返回错误状态 1 dpkg: 依赖关系问题使得 mysql-server 的配置工作不能继续: mysql-server 依赖于 mysql-server-5.7;然而: 软件包 mysql-server-5.7 尚未配置。 dpkg: 处理软件包 mysql-server (--configure)时出错: 依赖关系问题 - 仍未被配置 正在处理用于 libc-bin (2.23-0ubuntu9) 的触发器 ... 因为错误消息指示这是由于上一个问题导致的错误,没有写入 apport 报告。 正在处理用于 systemd (229-4ubuntu17) 的触发器 ... 正在处理用于 ureadahead (0.100.0-19) 的触发器 ... 在处理时有错误发生: mysql-server-5.7 mysql-server E: Sub-process /usr/bin/dpkg returned an error code (1) 然后上网百度,基本上所有博客说的方法都是一样的。就是删除再弄 sudo rm /var/lib/mysql/ -R sudo rm /etc/mysql/ -R sudo apt-get autoremove mysql* --purge sudo apt-get remove apparmor // 输入Y回车 然后在装: sudo apt-get install mysql-server mysql-common //重新安装 我已经试过好几次了,都不行,每次删除之后,再安装,输入指令后, 然后就让设置密码,密码设置完后在过一会儿最后就又出现这个问题, 烦人,被这个问题困扰一下午了。我是刚接触linux系统,对这些根本 不了解,安装什么东西都是百度别人的教程,希望大神可以帮帮我, 出现这种情况是什么问题。

Ubuntu mysql的binlog只能放在/var/log/mysql下

mysql5.7 ubuntu16.4 binlog只能放在mysql配置文件默认的/var/log/mysql下,将路径修改为其他位置则提示权限不足 属主属组权限都给了myql,目录改为了777,依旧不行 /var/log/mysql目录权限 ```. root@ubuntu:/var/log/mysql# ll /var/log/mysql/ total 208 drwxr-x--- 2 mysql adm 4096 Jul 25 11:51 ./ drwxrwxr-x 7 root syslog 4096 Jul 25 10:08 ../ -rw-r----- 1 mysql adm 177095 Jul 25 11:51 error.log -rw-r----- 1 mysql mysql 177 Jul 25 11:39 mysql-bin.000001 -rw-r----- 1 mysql mysql 177 Jul 25 11:44 mysql-bin.000002 -rw-r----- 1 mysql mysql 177 Jul 25 11:49 mysql-bin.000003 -rw-r----- 1 mysql mysql 154 Jul 25 11:51 mysql-bin.000004 -rw-r----- 1 mysql mysql 128 Jul 25 11:51 mysql-bin.index ``` 属主属组完全相同但是还是报错 ```. 2019-07-25T03:50:31.499690Z 0 [Warning] Changed limits: max_open_files: 1024 (requested 5000) 2019-07-25T03:50:31.499875Z 0 [Warning] Changed limits: table_open_cache: 431 (requested 2000) 2019-07-25T03:50:31.678797Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). 2019-07-25T03:50:31.681269Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.27-0ubuntu0.16.04.1-log) starting as process 22722 ... mysqld: File '/log/mysql-bin.index' not found (Errcode: 13 - Permission denied) 2019-07-25T03:50:31.685861Z 0 [ERROR] Aborting 2019-07-25T03:50:31.685940Z 0 [Note] Binlog end 2019-07-25T03:50:31.686079Z 0 [Note] /usr/sbin/mysqld: Shutdown complete 2019-07-25T03:50:46.822469Z 0 [Warning] Changed limits: max_open_files: 1024 (requested 5000) 2019-07-25T03:50:46.822565Z 0 [Warning] Changed limits: table_open_cache: 431 (requested 2000) 2019-07-25T03:50:47.029772Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). 2019-07-25T03:50:47.032072Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.27-0ubuntu0.16.04.1-log) starting as process 22773 ... mysqld: File '/log/mysql-bin.index' not found (Errcode: 13 - Permission denied) 2019-07-25T03:50:47.037520Z 0 [ERROR] Aborting 2019-07-25T03:50:47.037610Z 0 [Note] Binlog end 2019-07-25T03:50:47.037763Z 0 [Note] /usr/sbin/mysqld: Shutdown complete 2019-07-25T03:51:17.533526Z 0 [Warning] Changed limits: max_open_files: 1024 (requested 5000) 2019-07-25T03:51:17.533655Z 0 [Warning] Changed limits: table_open_cache: 431 (requested 2000) 2019-07-25T03:51:17.791165Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). 2019-07-25T03:51:17.793337Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.27-0ubuntu0.16.04.1-log) starting as process 22853 ... mysqld: File '/log/mysql-bin.index' not found (Errcode: 13 - Permission denied) 2019-07-25T03:51:17.798406Z 0 [ERROR] Aborting 2019-07-25T03:51:17.798466Z 0 [Note] Binlog end 2019-07-25T03:51:17.799262Z 0 [Note] /usr/sbin/mysqld: Shutdown complete ```

怎么把win10和ubuntu的启动项合并在一起?

电脑是在固态硬盘里面装了win10系统,uefi启动,并且电脑有傲腾内存,所以开启了RST。这样一来装ubuntu的时候是无法识别到固态硬盘的,所以我把ubuntu装在了机械硬盘里面,并且以为无法识别固态所以也没办法在装ubuntu的时候就把ubuntu的启动项和win10的启动项合并。 现在就是在固态硬盘上和机械硬盘上各有一个efi分区,只能是启动的时候在bios里面切换设备启动顺序来实现不同系统的启动,或者f12进入boot manager选择启动设备,不知道有没有办法能把这两个efi合并在一起呢?让它变为正常双系统那样可选的界面,而不是去bios里面改。 我尝试了BOOTICE tool 增加了一个实模式,启动分区我选的是ubuntu系统所在的盘符(就是挂载点为/的),但是这个启动文件我感觉不对,但是也不会设置,最后的效果是有双系统的选择,但是选择ubuntu之后启动失败,提示找不到启动文件。 ![图片说明](https://img-ask.csdn.net/upload/202005/14/1589460164_893062.jpg) 我还尝试了easy uefi这里虽然能添加启动项,但是添加的启动项只能在boot manager里面出现,那就跟我原来一样了,并没有解决问题。 ![图片说明](https://img-ask.csdn.net/upload/202005/14/1589460416_300233.jpg) 所以不知道还有没有别的解决方法了

UBUNTU xwindow启动却不启动桌面系统,如何设置

ubuntu 使用图形界面启动,但是在启动的时候只启动xwindow,后面的界面系统不启动,替换成我的程序,应该如何做呢,请大神指点迷津。

Ubuntu无法正常启动,卡死在登录界面

采用sudo update,并且手动下载了最新订单dbus之后(因为自动apt-get更新的dubs库的时候总是出错),Ubuntu系统就卡死在启动界面了。启动信息如下图。会一直卡在depend那个地方。 ![图片说明](https://img-ask.csdn.net/upload/201810/31/1540967437_513045.jpg) 目前Ubuntu只能通过recovery模式进入到命令行里。之前工作都在这个电脑上,所以非常不想重装Ubuntu。想问针对启动错误,从哪里修复呢?跪求各位大神指点,谢谢!!!

Ubuntu上安装mysql问题

``` root@iZ113kj9tt6Z:~# apt-get install mysql-server Reading package lists... Done Building dependency tree Reading state information... Done You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies: mysql-server : Depends: mysql-server-5.5 but it is not going to be installed python-libvirt : Depends: libvirt0 (>= 0.9.8-2ubuntu17.22) but it is not going to be installed Recommends: libvirt-bin but it is not going to be installed E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution). ``` 小白求解答

ubuntu下mysql提示空间不足

第一次提示这个问题后我删除了var下面的log文件,但是删除后仍然是同样的提示. 无奈我只好把mysql卸载了又重新安装,又重新开机,但是重新要启动时:/etc/init.d mysql start,仍然提示同样的错误mysqlERROR: The partition with /var/lib/mysql is too full! 查看了空间的使用情况如下: zhang@zhang-Inspiron-N4050:~$ df Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda8 56721716 8023228 45794120 15% / none 4 0 4 0% /sys/fs/cgroup udev 965132 4 965128 1% /dev tmpfs 194948 1160 193788 1% /run none 5120 0 5120 0% /run/lock none 974740 80 974660 1% /run/shm none 102400 36 102364 1% /run/user zhang@zhang-Inspiron-N4050:~$ 希望高人可以不吝赐教,不胜感激. 为什么新安装的mysql都会提示空间太满呢?

在中国程序员是青春饭吗?

今年,我也32了 ,为了不给大家误导,咨询了猎头、圈内好友,以及年过35岁的几位老程序员……舍了老脸去揭人家伤疤……希望能给大家以帮助,记得帮我点赞哦。 目录: 你以为的人生 一次又一次的伤害 猎头界的真相 如何应对互联网行业的「中年危机」 一、你以为的人生 刚入行时,拿着傲人的工资,想着好好干,以为我们的人生是这样的: 等真到了那一天,你会发现,你的人生很可能是这样的: ...

程序员请照顾好自己,周末病魔差点一套带走我。

程序员在一个周末的时间,得了重病,差点当场去世,还好及时挽救回来了。

C++(数据结构与算法)78:---分而治之

一、分而治之的思想 分而治之方法与软件设计的模块化方法非常相似 分而治之通常不用于解决问题的小实例,而要解决一个问题的大实例。一般步骤为: ①把一个大实例分为两个或多个更小的实例 ②分别解决每个小实例 ③把这些小实例的解组合成原始大实例的解 二、实际应用之找出假币 问题描述 一个袋子有16个硬币,其中只有一个是假币,这个假币比其他的真币重量轻(其他所有真币的重量都是相同的)...

springboot+jwt实现token登陆权限认证

一 前言 此篇文章的内容也是学习不久,终于到周末有时间码一篇文章分享知识追寻者的粉丝们,学完本篇文章,读者将对token类的登陆认证流程有个全面的了解,可以动态搭建自己的登陆认证过程;对小项目而已是个轻量级的认证机制,符合开发需求;更多精彩原创内容关注公主号知识追寻者,读者的肯定,就是对作者的创作的最大支持; 二 jwt实现登陆认证流程 用户使用账号和面发出post请求 服务器接受到请求后使用私...

技术大佬:我去,你写的 switch 语句也太老土了吧

昨天早上通过远程的方式 review 了两名新来同事的代码,大部分代码都写得很漂亮,严谨的同时注释也很到位,这令我非常满意。但当我看到他们当中有一个人写的 switch 语句时,还是忍不住破口大骂:“我擦,小王,你丫写的 switch 语句也太老土了吧!” 来看看小王写的代码吧,看完不要骂我装逼啊。 private static String createPlayer(PlayerTypes p...

win10暴力查看wifi密码

刚才邻居打了个电话说:喂小灰,你家wifi的密码是多少,我怎么连不上了。 我。。。 我也忘了哎,就找到了一个好办法,分享给大家: 第一种情况:已经连接上的wifi,怎么知道密码? 打开:控制面板\网络和 Internet\网络连接 然后右击wifi连接的无线网卡,选择状态 然后像下图一样: 第二种情况:前提是我不知道啊,但是我以前知道密码。 此时可以利用dos命令了 1、利用netsh wlan...

女程序员,为什么比男程序员少???

昨天看到一档综艺节目,讨论了两个话题:(1)中国学生的数学成绩,平均下来看,会比国外好?为什么?(2)男生的数学成绩,平均下来看,会比女生好?为什么?同时,我又联想到了一个技术圈经常讨...

副业收入是我做程序媛的3倍,工作外的B面人生是怎样的?

提到“程序员”,多数人脑海里首先想到的大约是:为人木讷、薪水超高、工作枯燥…… 然而,当离开工作岗位,撕去层层标签,脱下“程序员”这身外套,有的人生动又有趣,马上展现出了完全不同的A/B面人生! 不论是简单的爱好,还是正经的副业,他们都干得同样出色。偶尔,还能和程序员的特质结合,产生奇妙的“化学反应”。 @Charlotte:平日素颜示人,周末美妆博主 大家都以为程序媛也个个不修边幅,但我们也许...

MySQL数据库面试题(2020最新版)

文章目录数据库基础知识为什么要使用数据库什么是SQL?什么是MySQL?数据库三大范式是什么mysql有关权限的表都有哪几个MySQL的binlog有有几种录入格式?分别有什么区别?数据类型mysql有哪些数据类型引擎MySQL存储引擎MyISAM与InnoDB区别MyISAM索引与InnoDB索引的区别?InnoDB引擎的4大特性存储引擎选择索引什么是索引?索引有哪些优缺点?索引使用场景(重点)...

如果你是老板,你会不会踢了这样的员工?

有个好朋友ZS,是技术总监,昨天问我:“有一个老下属,跟了我很多年,做事勤勤恳恳,主动性也很好。但随着公司的发展,他的进步速度,跟不上团队的步伐了,有点...

我入职阿里后,才知道原来简历这么写

私下里,有不少读者问我:“二哥,如何才能写出一份专业的技术简历呢?我总感觉自己写的简历太烂了,所以投了无数份,都石沉大海了。”说实话,我自己好多年没有写过简历了,但我认识的一个同行,他在阿里,给我说了一些他当年写简历的方法论,我感觉太牛逼了,实在是忍不住,就分享了出来,希望能够帮助到你。 01、简历的本质 作为简历的撰写者,你必须要搞清楚一点,简历的本质是什么,它就是为了来销售你的价值主张的。往深...

程序员写出这样的代码,能不挨骂吗?

当你换槽填坑时,面对一个新的环境。能够快速熟练,上手实现业务需求是关键。但是,哪些因素会影响你快速上手呢?是原有代码写的不够好?还是注释写的不够好?昨夜...

带了6个月的徒弟当了面试官,而身为高级工程师的我天天修Bug......

即将毕业的应届毕业生一枚,现在只拿到了两家offer,但最近听到一些消息,其中一个offer,我这个组据说客户很少,很有可能整组被裁掉。 想问大家: 如果我刚入职这个组就被裁了怎么办呢? 大家都是什么时候知道自己要被裁了的? 面试软技能指导: BQ/Project/Resume 试听内容: 除了刷题,还有哪些技能是拿到offer不可或缺的要素 如何提升面试软实力:简历, 行为面试,沟通能...

优雅的替换if-else语句

场景 日常开发,if-else语句写的不少吧??当逻辑分支非常多的时候,if-else套了一层又一层,虽然业务功能倒是实现了,但是看起来是真的很不优雅,尤其是对于我这种有强迫症的程序"猿",看到这么多if-else,脑袋瓜子就嗡嗡的,总想着解锁新姿势:干掉过多的if-else!!!本文将介绍三板斧手段: 优先判断条件,条件不满足的,逻辑及时中断返回; 采用策略模式+工厂模式; 结合注解,锦...

!大部分程序员只会写3年代码

如果世界上都是这种不思进取的软件公司,那别说大部分程序员只会写 3 年代码,恐怕就没有程序员这种职业。

离职半年了,老东家又发 offer,回不回?

有小伙伴问松哥这个问题,他在上海某公司,在离职了几个月后,前公司的领导联系到他,希望他能够返聘回去,他很纠结要不要回去? 俗话说好马不吃回头草,但是这个小伙伴既然感到纠结了,我觉得至少说明了两个问题:1.曾经的公司还不错;2.现在的日子也不是很如意。否则应该就不会纠结了。 老实说,松哥之前也有过类似的经历,今天就来和小伙伴们聊聊回头草到底吃不吃。 首先一个基本观点,就是离职了也没必要和老东家弄的苦...

2020阿里全球数学大赛:3万名高手、4道题、2天2夜未交卷

阿里巴巴全球数学竞赛( Alibaba Global Mathematics Competition)由马云发起,由中国科学技术协会、阿里巴巴基金会、阿里巴巴达摩院共同举办。大赛不设报名门槛,全世界爱好数学的人都可参与,不论是否出身数学专业、是否投身数学研究。 2020年阿里巴巴达摩院邀请北京大学、剑桥大学、浙江大学等高校的顶尖数学教师组建了出题组。中科院院士、美国艺术与科学院院士、北京国际数学...

为什么你不想学习?只想玩?人是如何一步一步废掉的

不知道是不是只有我这样子,还是你们也有过类似的经历。 上学的时候总有很多光辉历史,学年名列前茅,或者单科目大佬,但是虽然慢慢地长大了,你开始懈怠了,开始废掉了。。。 什么?你说不知道具体的情况是怎么样的? 我来告诉你: 你常常潜意识里或者心理觉得,自己真正的生活或者奋斗还没有开始。总是幻想着自己还拥有大把时间,还有无限的可能,自己还能逆风翻盘,只不是自己还没开始罢了,自己以后肯定会变得特别厉害...

男生更看重女生的身材脸蛋,还是思想?

往往,我们看不进去大段大段的逻辑。深刻的哲理,往往短而精悍,一阵见血。问:产品经理挺漂亮的,有点心动,但不知道合不合得来。男生更看重女生的身材脸蛋,还是...

为什么程序员做外包会被瞧不起?

二哥,有个事想询问下您的意见,您觉得应届生值得去外包吗?公司虽然挺大的,中xx,但待遇感觉挺低,马上要报到,挺纠结的。

当HR压你价,说你只值7K,你该怎么回答?

当HR压你价,说你只值7K时,你可以流畅地回答,记住,是流畅,不能犹豫。 礼貌地说:“7K是吗?了解了。嗯~其实我对贵司的面试官印象很好。只不过,现在我的手头上已经有一份11K的offer。来面试,主要也是自己对贵司挺有兴趣的,所以过来看看……”(未完) 这段话主要是陪HR互诈的同时,从公司兴趣,公司职员印象上,都给予对方正面的肯定,既能提升HR的好感度,又能让谈判气氛融洽,为后面的发挥留足空间。...

面试:第十六章:Java中级开发

HashMap底层实现原理,红黑树,B+树,B树的结构原理 Spring的AOP和IOC是什么?它们常见的使用场景有哪些?Spring事务,事务的属性,传播行为,数据库隔离级别 Spring和SpringMVC,MyBatis以及SpringBoot的注解分别有哪些?SpringMVC的工作原理,SpringBoot框架的优点,MyBatis框架的优点 SpringCould组件有哪些,他们...

早上躺尸,晚上干活:硅谷科技公司这么流行迟到?

硅谷科技公司上班时间OPEN早已不是什么新鲜事,早九晚五是常态,但有很多企业由于不打卡,员工们10点、11点才“姗姗来迟”的情况也屡见不鲜。 这种灵活的考勤制度为人羡慕,甚至近年来,国内某些互联网企业也纷纷效仿。不过,硅谷普遍弹性的上班制度是怎么由来的呢?这种“流行性迟到”真的有那么轻松、悠哉吗? 《动态规划专题班》 课程试听内容: 动态规划的解题要领 动态规划三大类 求最值/计数/可行性 常...

面试阿里p7,被按在地上摩擦,鬼知道我经历了什么?

面试阿里p7被问到的问题(当时我只知道第一个):@Conditional是做什么的?@Conditional多个条件是什么逻辑关系?条件判断在什么时候执...

Python爬虫,高清美图我全都要(彼岸桌面壁纸)

爬取彼岸桌面网站较为简单,用到了requests、lxml、Beautiful Soup4

无代码时代来临,程序员如何保住饭碗?

编程语言层出不穷,从最初的机器语言到如今2500种以上的高级语言,程序员们大呼“学到头秃”。程序员一边面临编程语言不断推陈出新,一边面临由于许多代码已存在,程序员编写新应用程序时存在重复“搬砖”的现象。 无代码/低代码编程应运而生。无代码/低代码是一种创建应用的方法,它可以让开发者使用最少的编码知识来快速开发应用程序。开发者通过图形界面中,可视化建模来组装和配置应用程序。这样一来,开发者直...

面试了一个 31 岁程序员,让我有所触动,30岁以上的程序员该何去何从?

最近面试了一个31岁8年经验的程序猿,让我有点感慨,大龄程序猿该何去何从。

大三实习生,字节跳动面经分享,已拿Offer

说实话,自己的算法,我一个不会,太难了吧

程序员垃圾简历长什么样?

已经连续五年参加大厂校招、社招的技术面试工作,简历看的不下于万份 这篇文章会用实例告诉你,什么是差的程序员简历! 疫情快要结束了,各个公司也都开始春招了,作为即将红遍大江南北的新晋UP主,那当然要为小伙伴们做点事(手动狗头)。 就在公众号里公开征简历,义务帮大家看,并一一点评。《启舰:春招在即,义务帮大家看看简历吧》 一石激起千层浪,三天收到两百多封简历。 花光了两个星期的所有空闲时...

Java岗开发3年,公司临时抽查算法,离职后这几题我记一辈子

前几天我们公司做了一件蠢事,非常非常愚蠢的事情。我原以为从学校出来之后,除了找工作有测试外,不会有任何与考试有关的事儿。 但是,天有不测风云,公司技术总监、人事总监两位大佬突然降临到我们事业线,叫上我老大,给我们组织了一场别开生面的“考试”。 那是一个风和日丽的下午,我翘着二郎腿,左手端着一杯卡布奇诺,右手抓着我的罗技鼠标,滚动着轮轴,穿梭在头条热点之间。 “淡黄的长裙~蓬松的头发...

立即提问
相关内容推荐