问题描述:[项目登陆的时候一般都是没问题的,但是又时候登陆会出现卡住。
补充描述:有的时候卡住一段时间(时间稍长)之后,也能登陆。在登陆某个账户又退出之后电脑的cpu会连续在50%以上,这种情况出现后比较容易出现登陆卡住的现象,有时候甚至会出现提示tomcat重启。
项目信息:web端项目Spring、Hibernate注解,DWR注解。数据库:MySQL。服务器:tomcat
解决过程:刚开始认为有可能是数据库死锁或者计算机的内存不够,不过后来看了数据库的InnoDB信息和机器任务管理器之后均被排除。
提问:这种情况是不是tomcat服务器出了某些问题,例如tomcat服务器的启动内存等等
希望大家能够提出有可能的问题,并根据自己提出的问题,做出验证或者解决的相应处理
下面是MySql数据库InnoDB信息:
- HTML code
----------------------+| InnoDB | |=====================================110908 13:27:36 INNODB MONITOR OUTPUT=====================================Per second averages calculated from the last 52 seconds----------SEMAPHORES----------OS WAIT ARRAY INFO: reservation count 4, signal count 4Mutex spin waits 0, rounds 20, OS waits 0RW-shared spins 8, OS waits 4; RW-excl spins 0, OS waits 0------------TRANSACTIONS------------Trx id counter 0 430612Purge done for trx's n:o < 0 429783 undo n:o < 0 0History list length 3LIST OF TRANSACTIONS FOR EACH SESSION:---TRANSACTION 0 0, not started, OS thread id 2520MySQL thread id 16, query id 580 localhost 127.0.0.1 rootshow innodb status---TRANSACTION 0 0, not started, OS thread id 2532MySQL thread id 13, query id 579 callcenter 192.168.8.247 root---TRANSACTION 0 430611, ACTIVE 128 sec, OS thread id 1624 fetching rows, thread declared inside InnoDB 452mysql tables in use 13, locked 0MySQL thread id 15, query id 552 callcenter 192.168.8.247 root Sending dataSELECT * FROM Models WHERE Gid IN (SELECT Gid FROM Models WHERE showMenu = 1 and state=1 And appModelGid = '6fe8a93f-64b3-d10f-964f-5aaa08191e5e' and Gid in(SELECT parent_id FROM Models WHERE Gid IN (SELECT Model_id FROM Actions WHERE GidIN (SELECT actions_id FROM Roles_Actions WHERE roles_id = '1b86fe4d-3e7b-2e30-e602-aaf71c48f435,9cab2734-e92d-831c-2e87-e30306a0bcc9' ))))or Gid IN (SELECT Gid FROM Models WHERE showMenu = 1 and state=1 And appModelGid = '6fe8a93f-64b3-d10f-964f-5aaa08191e5e' and Gid in(SELECT Model_id FROM Actions WHERE Gid IN (SELECT actions_id FROM Roles_Actions WTrx read view will not see trx with id >= 0 430612, sees < 0 430612--------FILE I/O--------I/O thread 0 state: wait Windows aio (insert buffer thread)I/O thread 1 state: wait Windows aio (log thread)I/O thread 2 state: wait Windows aio (read thread)I/O thread 3 state: wait Windows aio (write thread)Pending normal aio reads: 0, aio writes: 0, ibuf aio reads: 0, log i/o's: 0, sync i/o's: 0Pending flushes (fsync) log: 0; buffer pool: 0226 OS file reads, 10 OS file writes, 10 OS fsyncs0.00 reads/s, 0 avg bytes/read, 0.00 writes/s, 0.00 fsyncs/s-------------------------------------INSERT BUFFER AND ADAPTIVE HASH INDEX-------------------------------------Ibuf: size 1, free list len 0, seg size 2,0 inserts, 0 merged recs, 0 mergesHash table size 1187107, node heap has 1 buffer(s)0.52 hash searches/s, 0.00 non-hash searches/s---LOG---Log sequence number 0 292717601Log flushed up to 0 292717601Last checkpoint at 0 2927176010 pending log writes, 0 pending chkp writes11 log i/o's done, 0.00 log i/o's/second----------------------BUFFER POOL AND MEMORY----------------------Total memory allocated 327041672; in additional pool allocated 1551360Dictionary memory allocated 43208Buffer pool size 18304Free buffers 18215Database pages 88Modified db pages 0Pending reads 0Pending writes: LRU 0, flush list 0, single page 0Pages read 88, created 0, written 20.00 reads/s, 0.00 creates/s, 0.00 writes/sBuffer pool hit rate 1000 / 1000--------------ROW OPERATIONS--------------1 queries inside InnoDB, 0 queries in queue2 read views open inside InnoDBMain thread id 1512, state: waiting for server activityNumber of rows inserted 0, updated 0, deleted 0, read 4057725880.00 inserts/s, 0.00 updates/s, 0.00 deletes/s, 712664.89 reads/s----------------------------END OF INNODB MONITOR OUTPUT============================