Java Date存入MySQL datetime字段差1秒,甚至跨天的问题 suny

一、问题重现:

 

...

CKEditor 5 自定义图片上传组件(Angular16) suny

1、配置编辑器(article.component.html):

<ckeditor [editor]="contentEditor" [data]="contentData" [config]="ckConfig" … ></ckeditor>

 

...

CentOS 8.2 安装Nginx 1.24(支持HTTPS)详细步骤 suny

1、下载nginx
# wget https://nginx.org/download/nginx-1.24.0.tar.gz
# tar -zxvf nginx-1.24.0.tar.gz

 

2、安装ssl模块:
# yum -y install openssl openssl-devel

...

CentOS 8.2 安装MySQL8.2详细步骤 suny

1、下载 安装包:

# wget https://dev.mysql.com/get/Downloads/MySQL-8.2/mysql-8.2.0-linux-glibc2.28-x86_64.tar.xz

 

...

使用jQuery和HTML5 扫描条形码输入 suny

由于工作需要,今天探索了一下在手机端web调用摄像头扫描的方式,实现了条形码的输入。

本次采用的是:quaggaJS 插件:

官网地址:https://serratus.github.io/quaggaJS/

...

CentOS 6.5 下安装 Redis 3.0.3 rainy

#wget http://download.redis.io/releases/redis-3.0.3.tar.gz

#tar xvzf redis-3.0.3.tar.gz

#cd redis-3.0.3

...

常用数据库validationQuery语句 suny

在配置数据库连接池的时候,有一个选项validationQuery,该选项用来验证数据库连接的有效性,下表是从网上收集的常用数据库的validationQuery语句。

数据库 validationQuery
Oracle select 1 from dual
DB2 select 1 from sysibm.sysdummy1
mysql select 1
microsoft sql select 1
hsqldb select 1 from INFORMATION_SCHEMA.SYSTEM_USERS
postgresql select version();
ingres select 1
derby select 1
H2 select 1

CentOS 安装 SVN 服务器 suny

1、安装SVN服务端:
[root@localhost ~]# yum install subversion

2、判断SVN是否安装成功:
[root@localhost ~]# svnserve --version
svnserve, version 1.6.11 (r934486)
...

3、创建SVN库目录
[root@localhost /]# mkdir /opt/svn/repos -p
[root@localhost /]# svnadmin create /opt/svn/repos
[root@localhost /]# ll /opt/svn/repos/
total 24
drwxr-xr-x. 2 root root 4096 Apr 2 11:22 conf
drwxr-sr-x. 6 root root 4096 Apr 2 11:22 db
-r--r--r--. 1 root root 2 Apr 2 11:22 format
drwxr-xr-x. 2 root root 4096 Apr 2 11:22 hooks
drwxr-xr-x. 2 root root 4096 Apr 2 11:22 locks
-rw-r--r--. 1 root root 229 Apr 2 11:22 README.txt

...

【转】查询CentOS查看系统内核版本,系统版本 suny

1. 查看centos内核的版本:
1)
[root@localhost ~]# cat /proc/version
Linux version 2.6.18-194.el5 (mockbuild@builder10.centos.org) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)) #1 SMP Fri Apr 2 14:58:14 EDT 2010
2)
[root@localhost ~]# uname -a
Linux localhost.localdomain 2.6.18-194.el5 #1 SMP Fri Apr 2 14:58:14 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux
3)
[root@localhost ~]# uname -r
2.6.18-194.el5

2. 查看linux版本:
1) 列出所有版本信息,
[root@localhost ~]# lsb_release -a
LSB Version: :core-3.1-amd64:core-3.1-ia32:core-3.1-noarch:graphics-3.1-amd64:graphics-3.1-ia32:graphics-3.1-noarch
Distributor ID: CentOS
Description: CentOS release 5.5 (Final)
Release: 5.5
Codename: Final
注:这个命令适用于所有的linux,包括Redhat、SuSE、Debian等发行版。
2) 执行cat /etc/issue,例如如下:
[root@localhost ~]# cat /etc/issue
CentOS release 5.5 (Final)
Kernel r on an m
3) 执行cat /etc/redhat-release ,例如如下:
[root@localhost ~]# cat /etc/redhat-release
CentOS release 5.5 (Final)

3. 查看系统是64位还是32位:
1、getconf LONG_BIT or getconf WORD_BIT
[root@localhost ~]# getconf LONG_BIT
64
2、file /bin/ls
[root@localhost ~]# file /bin/ls
/bin/ls: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), for GNU/Linux 2.6.9, stripped
3、lsb_release -a
[root@localhost ~]# lsb_release -a
LSB Version: :core-3.1-amd64:core-3.1-ia32:core-3.1-noarch:graphics-3.1-amd64:graphics-3.1-ia32:graphics-3.1-noarch
Distributor ID: CentOS
Description: CentOS release 5.5 (Final)
Release: 5.5
Codename: Final

...

CentOS 防火墙 开放80端口 suny

开放端口:
[root@WX32 ~]# iptables -I INPUT -p tcp --dport 80 -j ACCEPT

保存配置:
[root@WX32 ~]# service iptables save
Saving firewall rules to /etc/sysconfig/iptables:          [  OK  ]

重启防火墙:
[root@WX32 ~]# service iptables restart
Flushing firewall rules:                                   [  OK  ]
Setting chains to policy ACCEPT: filter                    [  OK  ]
Unloading iptables modules:                                [  OK  ]
Applying iptables firewall rules:                          [  OK  ]
Loading additional iptables modules: ip_conntrack_netbios_n[  OK  ]

...

Total:13312345678910›››|14 Pages