在使用 Linux 的过程中,有时候需要临时获取 root 权限来执行命令时,一般通过在命令前添加 sudo 来解决. 但是第一次使用 sudo 时,有可能会得到这样一个错误提示 xxx is not in the sudoers file.This incident will be reported.的解决方法 xxx代表你当前的用户名. 出现该问题的原因是,在通过 sudo 获取 root 权限之前,用户需要先获得使用 sudo 命令的权限. 通过简单的搜索,我得知 sudo 命令的配置由…
MySQL数据库,当我尝试在A表中设置B表的主键为外键时,报出错误:#1452 - Cannot add or update a child row: a foreign key constraint fails 于是去搜索了一下 "#1452 - Cannot add or update a child row: a foreign key constraint fails" 的含义与解决方法,根据这篇博文去排查了报错原因,排除了可能1和可能2,然后去研究可能3的具体含义,一开始并…