[레거시코드] [라이믹스] 휴지통 비우기가 되지 않음.
2021.03.10 00:17
49
0
https://eond.com/438524
object(HotopayModel)#817 (23) { ["error"]=> int(0) ["message"]=> string(7) "success" ["variables"]=> array(0) { } ["httpStatusCode"]=> int(200) ["module"]=> string(7) "hotopay" ["module_info"]=> NULL ["origin_module_info"]=> NULL ["module_config"]=> NULL ["module_path"]=> string(52) "/home/eond/web/eond.com/public_html/modules/hotopay/" ["xml_info"]=> NULL ["module_srl"]=> NULL ["mid"]=> NULL ["act"]=> NULL ["template_path"]=> NULL ["template_file"]=> NULL ["layout_path"]=> NULL ["layout_file"]=> NULL ["edited_layout_file"]=> NULL ["stop_proc"]=> bool(false) ["user"]=> object(Rhymix\Framework\Helpers\SessionHelper)#816 (20) { ["member_srl"]=> int(0) ["user_id"]=> NULL ["user_name"]=> NULL ["nick_name"]=> NULL ["email_address"]=> NULL ["phone_number"]=> NULL ["homepage"]=> NULL ["blog"]=> NULL ["birthday"]=> NULL ["denied"]=> NULL ["status"]=> NULL ["is_admin"]=> string(1) "N" ["is_site_admin"]=> NULL ["profile_image"]=> NULL ["image_name"]=> NULL ["image_mark"]=> NULL ["signature"]=> NULL ["description"]=> NULL ["group_list"]=> array(0) { } ["menu_list"]=> array(0) { } } ["request"]=> object(Rhymix\Framework\Request)#10 (13) { ["method"]=> string(3) "GET" ["compat_method"]=> string(3) "GET" ["url"]=> string(21) "xe/438524/page/465436" ["hostname"]=> string(8) "eond.com" ["domain"]=> NULL ["protocol"]=> string(5) "https" ["callback_function"]=> string(0) "" ["_route_status":protected]=> int(200) ["_route_options":protected]=> object(stdClass)#11 (5) { ["cache_control"]=> bool(true) ["check_csrf"]=> bool(true) ["is_forwarded"]=> bool(false) ["is_indexable"]=> bool(true) ["enable_session"]=> bool(true) } ["module"]=> string(5) "board" ["mid"]=> string(2) "xe" ["act"]=> string(16) "dispBoardContent" ["args"]=> array(4) { ["document_srl"]=> string(6) "438524" ["page"]=> int(1) ["mid"]=> string(2) "xe" ["act"]=> string(16) "dispBoardContent" } } ["ajaxRequestMethod"]=> array(2) { [0]=> string(6) "XMLRPC" [1]=> string(4) "JSON" } ["gzhandler_enable"]=> bool(true) }

블루윙즈 서버를 세팅 후 휴지통 비우기가 되지 않는다는 보고가 있었습니다.

이는 라이믹스의 버그가 아니라 단순 기능 미흡 정도로 봐야할텐데요,

서버의 성능이 좌우되겠지만, 설정된 서버의 php 메모리가 낮아서가 이유입니다.


[09-Mar-2021 23:38:04 Etc/GMT-9] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /home/bluewings/www/modules/trash/model/TrashVO.php on line 57
[09-Mar-2021 23:38:04 Etc/GMT-9] PHP Fatal Error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in modules/trash/model/TrashVO.php on line 57
[09-Mar-2021 23:38:04 Etc/GMT-9] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /home/bluewings/www/common/autoload.php on line 127
[09-Mar-2021 23:38:04 Etc/GMT-9] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in Unknown on line 0


해당 오류는 위와 같았습니다.



/etc/php/7.4/php.ini


위 파일에서 memory_limit = 128MB를 256MB로 수정해줍니다.


4만 5천개의 게시물을 비우려니 메모리가 많이 필요한가 봅니다.


max_execution_time = 30 -> 120
memory_list = 128 -> 512MB


service php7.4-fpm restart
service nginx restart


vi /home/bluewings/logs/error.log


콘텐츠->휴지통의 경우

'휴지통 비우기' 버튼이 있기는 하나,  휴지통의 글이 아주 많은 경우라면

이걸로 비우면 중간에 메모리 에러가 발생하게 된다.

 

DB 에서 직접 휴지통 글을 제거하는 방법도 있긴하지만  ( xe_trash 테이블 )

휴지통으로 옮길때 XE 자체는,  댓글을 삭제하지 않고,  첨부파일도 삭제 않고 대기로 상태 변경을 하고, 포인트 회수 나 기타 관련트리거들이 전부 실행이 안 되기에

( 실제 실행되는건,  documents 테이블에서 글자체만 제거 ,  카테고리수 변경, 첨부파일 대기상태로 변경 뿐이다.  

 그 이외에는 휴지통으로 옮길때 처리하는게 아니라,  휴지통에 있던 글을 비우기로 삭제될때 이뤄진다 )

 

휴지통 비우기가 에러나면,  결국 휴지통 목록에서

우측의 checkbox 전체선택으로 현재 목록의 글을 다 선택한 후, '삭제'버튼으로 삭제해나가는 방법 뿐이다.

단, Core 기본은 한번에 30개만 목록에 노출되어있는데, 30개씩 일일이 지우는게 너무 지나친 노가다가 되면

이 목록의 노출개수를 늘리면 된다.


휴지통 목록은

modules/trash/trash.admin.view.php 에서
dispTrashAdminList  함수에서

 

$args->list_count = 30;  값을 늘리시면 목록수가 늘어난다.  이걸 좀 늘리면서 하면 노가다가 좀 줄게 된다.
( 그렇다고 아주 크게 늘리면 어차피 일괄선택 후 처리하다가 에러 뜰거기에, 적당히 늘려가면서 사용 서버가 버티는 범위로 정해주는게 좋다 )



( 대기파일은 휴지통으로 이동된 글의 첨부파일 / 글 이나 댓글 등록시 첨부했다가 글이나 댓글 등록하지 않은 경우 에 발생하는거기에..) | 복제된 문서입니다. (원본) http://sejin7940.co.kr/xe_tips/112299

저는 이렇게 500개로 설정해두고 한 페이지씩 지워갔습니다.

800, 1000은 아예 뻗어버리더군요.


modules/trash/queries/getTrashList.xml

<list_count var="list_count" default="500" />


추가로 이 파일도 같이 수정해야하더군요.


memory_list을 20480M 으로 수정해도 1000개, 800개는 무리더군요.

500개 정도로 타협봤습니다;


참조

http://sejin7940.co.kr/xe_tips/112299


라이믹스는 이온디와 함께

닫기

마이페이지

로그인을 해주세요

네이버로 로그인