Saturday, March 11, 2017

Oracle Recover DB - ORA-01194: file 1 needs more recovery to be consistent

Method 1:
1) Start the database in mount state
SQL> startup mount;
2) Recover the database.
SQL> recover database;
If you come across below error
ORA-00283: recovery session canceled due to errors
ORA-01610: recovery using the BACKUP CONTROLFILE option must be done
 
ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01194: file 1 needs more recovery to be consistent
ORA-01110: data file 1: ‘D:\ORACLE\PRODUCT\10.2.0\ORADATA\DBTEST\SYSTEM01.DBF’
then, do the following
1)
SQL> recover database using backup controlfile until cancel;
ORA-00279: change 766152 generated at 03/16/2013 12:12:04 needed for thread 1
ORA-00289: suggestion :
/u01/app/oracle/flash_recovery_area/DUPDB/archivelog/2013_03_16/o1_mf_1_14_%u_.arc
ORA-00280: change 766152 for thread 1 is in sequence #14
Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2013_03_14/o1_mf_1_10_8n43no4v_.arc
ORA-00310: archived log contains sequence 10; sequence 14 required
ORA-00334: archived log:
'/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2013_03_14/o1_mf_1_10_8n43no4v_.arc'
ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01195: online backup of file 1 needs more recovery to be consistent
ORA-01110: data file 1:
'/u01/app/oracle/oradata/DUPDB/datafile/o1_mf_system_7qm3ck4o_.dbf'
2)
SQL> recover database using backup controlfile until cancel;
ORA-00279: change 766152 generated at 03/16/2013 12:12:04 needed for thread 1
ORA-00289: suggestion :
/u01/app/oracle/flash_recovery_area/DUPDB/archivelog/2013_03_16/o1_mf_1_14_%u_.arc
ORA-00280: change 766152 for thread 1 is in sequence #14
Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2013_03_14/o1_mf_1_11_8n43qq5j_.arc
ORA-00310: archived log contains sequence 11; sequence 14 required
ORA-00334: archived log:
'/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2013_03_14/o1_mf_1_11_8n43qq5j_.arc'
ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01195: online backup of file 1 needs more recovery to be consistent
ORA-01110: data file 1:
'/u01/app/oracle/oradata/DUPDB/datafile/o1_mf_system_7qm3ck4o_.dbf'
3)
SQL> recover database using backup controlfile until cancel;
ORA-00279: change 766152 generated at 03/16/2013 12:12:04 needed for thread 1
ORA-00289: suggestion :
/u01/app/oracle/flash_recovery_area/DUPDB/archivelog/2013_03_16/o1_mf_1_14_%u_.arc
ORA-00280: change 766152 for thread 1 is in sequence #14
Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2013_03_16/o1_mf_1_14_8n875owh_.arc
ORA-00279: change 769526 generated at 03/16/2013 12:48:13 needed for thread 1
ORA-00289: suggestion :
/u01/app/oracle/flash_recovery_area/DUPDB/archivelog/2013_03_16/o1_mf_1_15_%u_.arc
ORA-00280: change 769526 for thread 1 is in sequence #15
ORA-00278: log file
'/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2013_03_16/o1_mf_1_14_8n875
owh_.arc' no longer needed for this recovery
Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
cancel
Media recovery cancelled.
3) Open the database in resetlog mode
SQL> alter database open resetlogs;
4) Check the status
SQL> select instance_name, status from v$instance;
INSTANCE_NAME    STATUS
------------------------   -------------
DUPDB                  OPEN
SQL> select name, open_mode from v$database;
NAME      OPEN_MODE
----------    ------------------
DUPDB     READ WRITE


Method 2:
SQL> shutdown immediate
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.
Total System Global Area  530288640 bytes
Fixed Size                  2131120 bytes
Variable Size             310381392 bytes
Database Buffers          209715200 bytes
Redo Buffers                8060928 bytes
Database mounted.
SQL> ALTER SYSTEM SET "_allow_resetlogs_corruption"= TRUE SCOPE = SPFILE;
SQL> ALTER SYSTEM SET undo_management=MANUAL SCOPE = SPFILE;
SQL> shutdown immediate
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.
Total System Global Area  530288640 bytes
Fixed Size                  2131120 bytes
Variable Size             310381392 bytes
Database Buffers          209715200 bytes
Redo Buffers                8060928 bytes
Database mounted.
SQL> alter database open resetlogs;
Database altered.
SQL> CREATE UNDO TABLESPACE undo1 datafile '<ora_data_path>undo1_1.dbf' size 200m autoextend on maxsize unlimited;
Tablespace created.
SQL> ALTER SYSTEM SET undo_tablespace = undo1 SCOPE=spfile;
System altered.
SQL> alter system set undo_management=auto scope=spfile;
System altered.
SQL> shutdown immediate
SQL> startup

Tuesday, March 7, 2017

win 10 explorer cannot search

If that does not work for you, run the built-in search troubleshooter to find out more about it. To run it, do the following:
  1. Tap on the Windows-key, type Control Panel and hit enter.
  2. Alternatively, use the keyboard shortcut Windows-Pause to open the Control Panel if the above does not work. Click on "Control Panel Home" when the window opens.
  3. Select large or small icons under "view by".
  4. Click on Indexing options, and when the menu opens on the Advanced button.
  5. There you need to click on "troubleshoot search and indexing", and follow the instructions 

Monday, February 13, 2017

How to enable sa Account in SQL Server?

When you install the SQL Server using Windows Authentication mode, by default, the “sa” account is disabled. Sometimes, due to users/customers request, you may need to enable the sa account. You need to change the authentication mode for SQL server from Windows Authentication Mode to SQL Server and Windows Authentication Mode to use the sa account.
To Change the Authentication Mode:
Follow the steps mentioned below to change the authentication mode from Windows Authentication to SQL Server and Windows Authentication. You need to remember that, the SQL Server service needs to restart to make this change effective.
1. Login to the SQL server instance using SQL Server Management Studio. Right-click on the database instance, and go to Properties.
image
2. On the Server Properties page, Click on Security. Click on the radio button next to SQL Server and Windows Authentication mode, and click on OK to close the  Server Properties page.
image
3. Once you clicked on the Ok button, we will get the following screen:
image
As discussed earlier, we need to restart the SQL Server service to make this change effective. After restarting the SQL Server, the authentication mode will be changed to SQL Server and Windows Authentication mode.
Enable the sa Login:
1. Connect to the SQL Server instance using SSMS and go to Security. Expand Security, go to Logins.
2.  You can see the sa account is disabled when you install SQL Server using Windows Authentication mode.
image
3. Right-click on the sa account and go to Login Properties. Specify a complex password for the sa account. By default, the Enforce password policy is checked. (if you don’t want to provide a complex password for the sa account, you can uncheck this option. However, this is not recommended.)
image
4. Click on the Status page. By default, the sa account will be disabled. Click on the Enabled button to enable the sa account. Click on Ok to close the sa Login Properties.
image
Thus, sa account is enabled and you will be able to login to the SQL instance using the sa account.
If you want to use a script to enable the sa account, you can use the script mentioned below:
1: USE [master]
2: GO
3: ALTER LOGIN [sa] WITH PASSWORD=N'z43VGYT@Iu*60i'
4: GO
5: ALTER LOGIN [sa] ENABLE
6: GO

Wednesday, February 8, 2017

Khai báo tài khoản IMS của VNPT vào điện thoại IP, tổng đài ip và thiết bị ATA

Khai báo tài khoản SIP IMS của VNPT vào điện thoại IP
1. Khai báo cho các điện thoại IP Grandstream
Khai báo tài khoản IMS VNPT vào điện thoại IP
2. Khai báo cho các thiết bị ATA của Grandstream
a. Khai báo cho frofile
- Primary SIP Server: ims.vnpt.vn
- Outbound Proxy: 113.171.225.6:5062
IMS_ATA2
b. Khai báo tài khoản
- Sip User ID: Số điện thoại người dùng
- Authenticate ID: Số điện thoại kèm đuôi @ims.vnpt.vn (ví dụ: +84432001500@ims.vnpt.vn)
- Password: Mã password của số máy
- Name: Số điện thoại người sử dụng
IMS_ATA1
3. Khai báo tài khoản IMS của VNPT vào tổng đài IP Grandstream
Khai báo Sip Account IMS của VNPT
Vào giao diện web tổng đài -> vào Pbx -> Vào Voip Trunks -> Creat new Sip Trunk và thiết lập các thông số tài khoản tương tự như sau
VNPT_IMS2 VNPT_IMS1

Tuesday, January 24, 2017

Installing MsSQL extension on cPanel/WHM server.

Currently there is no script for installing php mssql extension in cpanel server. You have to install it manually.

You need to install a few modules before installing the MsSQL extension.

1. unixODBC

2. freeTDS

3. mssql.so


Do not use rpms as it will show lots of dependency errors. Better download the source file and compile it.

Install unixODBC package

Download source file and install using following steps.

-------
~]# wget http://www.unixodbc.org/unixODBC-2.2.14-p2.tar.gz
~]# tar -xvf unixODBC-2.2.12.tar.gz
~]# cd unixODBC-2.2.12
~]# ./configure -prefix=/usr/local -enable-gui=no    (make sure you use gui option set as 'no' else it will show error message as it don't have Qt package)
~]# make
~]# make install
------

Install freeTDS package

--------
1. Download from ftp://ftp.freetds.org/pub/freetds/old/0.82/freetds-0.82.tar.gz
2. tar -xvf freetds-0.82.tar.gz

3. ./configure -with-tdsver=8.0 -with-unixODBC=/usr/local

4. make

5. make install
---------

Configure freeTDS

1. Locate the freetds.conf and add the following entries. default location is /usr/local/etc/freetds.conf

[MSHOSTNAME]
host = MSHOSTNAME
port = 1433
tds version = 8.0

In cPanel servers the extensions are located at /home/cpeasyapache/src/php-x.x.x/ext. Navigate to the above directory and then to mssql directory.

cd /home/cpeasyapache/src/php-x.x.x/ext/mssql

phpize
./configure
make
make install 

The above commands will generate a copy of mssql.so in the installed extensions directory. Check and make sure that mssql.so is there and add the following to php.ini

---------
# php -i | grep php.ini
Configuration File (php.ini) Path => /usr/local/lib
Loaded Configuration File => /usr/local/lib/php.ini

# vim /usr/local/lib/php.ini
extension=”mssql.so”

-----------
Restart httpd and check the modules using the following command.

~]# php -m | grep mssql
mssql

Thursday, December 29, 2016

How to hide the All tab from the Menu bar in sugarcrm

How to Hide The ALL tab from the Menu bar 

Here i am explaining how to hide the All Tab Menu Bar from sugarcrm 6.4.4

STEP 1 :

Go to file
    /include/MVC/View/SugarView.php
open the file in the php editor

STEP 2 :

Go to line number 509 and comment the line
 $groupTabs[$app_strings['LBL_TABGROUP_ALL']]['modules'] = $fullModuleList;
below that add a new code
 $groupTabs[$app_strings['LBL_TABGROUP_ALL']]['modules'] = '';

So when you set that All menu tab only display one item under the subtab.

STEP 3 :

Now moving forward got to line number 513 and comment the line
$allGroup = $app_strings['LBL_TABGROUP_ALL'];


below that add a new code
  $allGroup = $app_strings['LBL_TABGROUP_ALL']  = '';


For the higher version means Sugarcrm 6.5.* use the following way

/include/MVC/View/SugarView.php

Find for the " $ss->assign("groupTabs",$groupTabs);"

just above this line put this code

//this code is used to hide the all tab

unset($groupTabs['All']);
$ss->assign("groupTabs",$groupTabs);


STEP 4:

 Now save the file and refresh your sugarcrm instance. you will not find the ALL menu tab.

Tuesday, December 27, 2016

Tìm kiếm file chia sẻ trong MediaFire

Những file bạn đã upload lên MediaFire, mặc dù không gửi link chia sẻ cho người khác, nhưng vẫn có người tải file của bạn. Và bạn cũng muốn tải file của người khác mà không cần có link?
A7.jpg
Do dịch vụ lưu trữ file MediaFire được rất nhiều người sử dụng nên có thể nói đây là một kho lưu trữ khổng lồ trên Internet. Để đáp ứng nhu cầu tìm kiếm file trong MediaFire, người dùng có thể sử dụng trang www.searchshared.com/mediafire.com/ (tập trung tìm kiếm trong MediaFire).
Hay sử dụng Google để tìm theo các cú pháp sau:
- Tìm nhạc: google: mp3|wma|ogg site:mediafire.com
- Tìm phim ảnh: google: asf|rm|avi|mp4|wmv|flv site:mediafire.com
- Tìm truyện tranh: google: cbr|cbz site:mediafire.com
- Tìm file: google: rar|zip|exe site:mediafire.com
Như vậy, khi bạn upload file lên dịch vụ này thì người khác có thể dễ dàng tìm thấy file của bạn khi sử dụng các công cụ tìm kiếm như trên.

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | Powerade Coupons