pC.NET

Welcome to oscc.kr



 우분투 10.04 php 5.2 적용
2010-05-03 13:50:47
Hit : 23816

작성자 : 피시키드
<td valign="top"> </td> I created a script solution for

<u>Reverting PHP to 5.2 in Lucid 10.04</u>

but i may not post it there so i tell you here now

create the script
Code:

"ltr" class="alt2">
#!/bin/bash
# by Ruben Barkow (rubo77) "_blank" href="http://www.entikey.z11.de/">http://www.entikey.z11.de/

# Originally Posted by Bachstelze http://ubuntuforums.org/showthread.php?p=9080474#post9080474
# OK, here's how to do the Apt magic to get PHP packages from the karmic repositories:

echo "Am I root?  "
if [ "$(whoami &2>/dev/null)" != "root" ] && [ "$(id -un &2>/dev/null)" != "root" ] ; then
  echo "  NO!

Error: You must be root to run this script.
Enter
sudo su
"
  exit 1
fi
echo "  OK";


# finish all apt-problems:
apt-get -f install

# remove all your existing PHP packages. You can list them with dpkg -l| grep php
PHPLIST=$(for i in $(dpkg -l | grep php|awk '{ print $2 }' ); do echo $i; done)
echo these pachets will be removed: $PHPLIST 
# you need not to purge, if you have upgraded from karmic:
aptitude remove $PHPLIST
# on a fresh install, you need purge:
# aptitude remove --purge $PHPLIST


#Create a file each in /etc/apt/preferences.d like this (call it for example /etc/apt/preferences.d/php5.2);
#
#Package: php5
#Pin: release a=karmic
#Pin-Priority: 991
#
#The big problem is that wildcards don't work, so you will need one such stanza for each PHP package you want to pull from karmic:

echo ''>/etc/apt/preferences.d/php5.2
for i in $PHPLIST ; do echo "Package: $i
Pin: release a=karmic
Pin-Priority: 991
">>/etc/apt/preferences.d/php5.2; done

# duplicate your existing sources.list replacing lucid with karmic and save it in sources.list.d:
#sed s/lucid/karmic/g /etc/apt/sources.list | sudo tee /etc/apt/sources.list.d/karmic.list

# better exactly only the needed sources, cause otherwise you can get a cachsize problem:
echo "# needed sources vor php5.2:
deb http://de.archive.ubuntu.com/ubuntu/ karmic main restricted
deb-src http://de.archive.ubuntu.com/ubuntu/ karmic main restricted

deb http://de.archive.ubuntu.com/ubuntu/ karmic-updates main restricted
deb-src http://de.archive.ubuntu.com/ubuntu/ karmic-updates main restricted

deb http://de.archive.ubuntu.com/ubuntu/ karmic universe
deb-src http://de.archive.ubuntu.com/ubuntu/ karmic universe
deb http://de.archive.ubuntu.com/ubuntu/ karmic-updates universe
deb-src http://de.archive.ubuntu.com/ubuntu/ karmic-updates universe

deb http://de.archive.ubuntu.com/ubuntu/ karmic multiverse
deb-src http://de.archive.ubuntu.com/ubuntu/ karmic multiverse
deb http://de.archive.ubuntu.com/ubuntu/ karmic-updates multiverse
deb-src http://de.archive.ubuntu.com/ubuntu/ karmic-updates multiverse

deb http://security.ubuntu.com/ubuntu karmic-security main restricted
deb-src http://security.ubuntu.com/ubuntu karmic-security main restricted
deb http://security.ubuntu.com/ubuntu karmic-security universe
deb-src http://security.ubuntu.com/ubuntu karmic-security universe
deb http://security.ubuntu.com/ubuntu karmic-security multiverse
deb-src http://security.ubuntu.com/ubuntu karmic-security multiverse
" >> /etc/apt/sources.list.d/karmic.list

aptitude update

apache2ctl restart

echo install new from karmic:
aptitude -t karmic install $PHPLIST

# at the end retry the modul libapache2-mod-php5 in case it didn't work the first time:
aptitude -t karmic install libapache2-mod-php5

apache2ctl restart
make it executeable:
Code:
"ltr" class="alt2">
chmod +x /usr/local/sbin/php5.2-downgrade
* 피시넷님에 의해서 게시물 이동되었습니다 (2010-05-05 17:50)

  피시키드
회원님의 소개글이 없습니다.
 6490
 83

잠깐!
글은 인터넷에서 자신을 나타내는 유일한 모습입니다.
한줄의 댓글이나 답글로도 피시키드님은 무척 기뻐할 것입니다.
댓글쓰기     작성자   패스워드


99
  SMT-A310 모뎀 정보 
 피시키드
79 2024/07/29
98
  TriGem 486G VGA포트 MLCC 추정값 
 피시키드
100 2024/06/20
97
  conner cp-342 정보 
 피시키드
93 2024/06/05
96
  대세엠케어 HS-589 서비스 메뉴얼 정보   1
 피시키드
97 2024/06/05
95
  venix-86, 386  
 피시키드
163 2023/09/04
94
  끄적끄적. 
 피시키드
197 2023/07/29
93
  벽걸이 에어컨 이전 설치비 없이 에어컨 분리하는 방법 (자가이전)  
 피시키드
184 2023/07/07
92
  아두이노 스피커 입력받아 구현 
 피시키드
155 2023/05/06
91
  트랜샌드 256m 관련 결제 
 피시키드
193 2023/02/13
90
  sizzix 커팅매트 사이즈 
 피시키드
212 2022/04/26
89
  화산실험 -추억- 
 피시넷
459 2021/07/31
88
  CentOS 6에서 httpd 서비스시 자꾸 403오류가 뜰때. 
 피시키드
494 2021/07/16
87
  MYSQL 사용시 mysql.sock이 생성안됩니다 할때는.. (2002오류포함) 
 피시키드
2508 2021/03/17
86
  오랜만이네요   1
 윤성일
754 2021/01/12
85
  제로보드4 게시판형식에 정이 있으나.... 
 피시키드
781 2021/01/10
84
  이동식 드라이브 문자명 변경 
 피시키드
815 2021/01/10
83
  식빵 
 피시키드
784 2020/12/23
82
  Windows 10 네트워크 오류 해결 방법 
 피시키드
1023 2020/08/11
81
  KT추가단말서비스 IP주소   1
 피시키드
1110 2020/08/05
80
  qoh99se windows10에서 하는방법. 
 피시키드
1127 2020/08/02
79
  마인크래프트 최적화 
 피시키드
1882 2020/06/10
78
  멀티 부팅 USB 만들기 (ISO이미지 기반) 
 피시키드
1215 2020/05/27
77
  포토샵 CS3 강제종료 현상시. 
 피시키드
1324 2020/05/23
76
  리눅스 패키지 관련 
 피시키드
1280 2020/04/19
75
  [Linux/Shell] 특정 단어가 포함된 파일을 찾아 삭제하기 
 피시키드
1185 2020/04/02
74
  엑박 컨트롤러 개조 
 피시키드
5458 2020/03/27
73
  editplus 빈줄 삭제 
 피시키드
1332 2019/12/12
72
  ssh자동 로그인 설정   1
 피시키드
1679 2019/11/08
71
  ckeditor 업로드 테스트 완료 
 피시넷
1691 2019/10/05
70
  random for only logics gate circuit 
 피시키드
1365 2019/10/04

1 [2][3][4]



Copyright (C) 1997-2025 All Rights Reserved.

Powered by
DNS server, DNS service 우분투 리눅스 웹서비스 AbuseIPDB Contributor Badge