所有由小潘发布的文章

喜欢分享的小潘.

Oracle EBS 应用用户审计日志记录

Oracle EBS已经存在表fnd_logins,可以通过设置配置文件对Oracle EBS用户登录行为进行记录,但默认没有打开。

默认情况下该表已经有大量的记录了,类型为Concurrent,猜测为用户提交并发请求的日志记录,Concurrent实际并没有什么作用:

可以通过配置文件设置,对用户登录进行记录:

配置文件:登录:审计层

建议值:用户

作用:记录用户登录日志

配置文件值含义
1) NONE – no audit enabled (Default value)

配置文件的默认值,不对用户登录进行记录


2) USER – audit user login to system, the logon time and the logoff time.

用户,记录用户的登录行为


3) RESPONSIBILITY – audit all the above + which responsibilities the user chose and how long he stayed in each responsibility.

RESPONSIBILITY,记录用户登录+用户什么时候进入某一责任,在每个责任停留时间


4) FORM – audit all the above + which forms the user used and how long he stayed in each form.

表单,记录用户登录+责任+用户什么时候打开哪个Forms界面


不同的日志,记录在不同的表里面:

1) USER – populates the FND_LOGINS table only.
2) RESPONSIBILITY – populates FND_LOGINS and FND_LOGIN_RESPONSIBILITIES tables.
3) FORM – populates FND_LOGINS, FND_LOGIN_RESPONSIBILITIES and FND_LOGIN_RESP_FORMS tables.

FND_LOGINS – holds information about users login to system, when and how long.
This table holds one row for each login.

FND_LOGIN_RESPONSIBILITIES – holds information about changes of responsibilities, when and how long being at each responsibility.
For each change this table holds one row with values that identify the user's login session, the user's current responsibility, and when the user is in the responsibility

FND_LOGIN_RESP_FORMS – holds information about using forms, when and how long.
This table holds one row for each form used in the same session with values that identify the user's login session, current responsibility, when and how long using each form.

注:此时可以通过 系统管理员-安全性-用户-监控,监控当前登录系统的用户

用户登录行为的一些报表

1.登录审计未成功注册

作用:用来打印出登录失败用户的时间以及用户

2.登录审计用户

作用:用户登录的历史记录

3.清除登录审计数据

作用:清除fnd_logins开头的表的历史记录,报表有一参数“审计时间”,小于该值的历史记录会被清除。


转载自:https://blog.csdn.net/sunansheng/article/details/52238499 
 

Linux下记录操作系统用户登录及操作日志

背景:Linux操作系统本身有默认部分功能的日志记录功能,比如用户登录信息可以在 “/var/log/aduit”目录下查到,但是如果想要查询到哪些操作系统用户进行了什么操作命令,需要独立做审计功能设置(相对麻烦),这里用另外一种方式来实现,不采用系统的审计功能,来记录操作系统的登录信息及所有操作日志信息。这样当系统出现误操作而造成重要的数据丢失,就能查到是谁操作的(当然需要先解决问题再定责)。 具体执行命令如下(注意备份):

root进入根目录编辑/etc/profile文件,在文件末尾加入下面代码:

[root@devfin]# cd
[root@devfin]# vi /etc/profile

#add by pm 20181221 record os users operation commands.

history
USER=`whoami`
USER_IP=`who -u am i 2>/dev/null| awk '{print $NF}'|sed -e 's/[()]//g'`
if [ “$USER_IP” = “” ]; then
USER_IP=`hostname`
fi
if [ ! -d /var/log/history ]; then
mkdir /var/log/history
chmod 777 /var/log/history
fi
if [ ! -d /var/log/history/${LOGNAME} ]; then
mkdir /var/log/history/${LOGNAME}
chmod 300 /var/log/history/${LOGNAME}
fi
export HISTSIZE=4096
DT=`date +"%Y%m%d_%H:%M:%S"`
export HISTFILE="/var/log/history/${LOGNAME}/${USER}@${USER_IP}_$DT"
chmod 600 /var/log/history/${LOGNAME}/*history* 2>/dev/null


以下界面是自己做实验的结果:

职场上,什么最痛?

职场上,什么最痛?

是升不了职吗?是加不了薪吗?如果你不断地追问自己,你会发现,都不是,你真正的焦虑来自于:你,看不清未来的道路。

你刚刚加入一个新公司,你不知道三个月以后能不能融得进去,你不知道怎么能让老板和同事都喜欢你;你在一家公司干了两三年了,干的都是重复的事,日复一日,年复一年,你不知道这样无休止的重复,什么时候是个头;你在一家公司干了五八年了,你的领导过得是什么样的生活,你看得一清二楚,他不就是你未来的样子吗?你憎恨这一眼看得到头的工作,但是你舍得走吗?

其实所有的问题都源自于你不知道五年以后你能坐到什么位置、管多少人、挣多少钱,你不知道你挣的那些钱,能给你和你的家人什么样的生活;你不知道二十年以后,你拿什么养活自己?

你的焦虑,其实来自于你对未来的不确定。

我们很多人都有个误区,认为职业发展,就是把职场当成了宫斗剧。

有些人,宫斗剧看多了,他们不停地算计别人,不停地希望获取上司和老板的好感。就像一个已经得宠的嫔妃,还是希望每天晚上皇上都来。他们以为,一定有那样一个数字,攒够了,就升了。比如皇上来宠幸100次,就升皇后了。所以他们攒着,盼着,算计着,很怕别人先被宠幸了100次,很怕自己没到100次就失宠了。

事实上,这是职场的真相吗?

关于职场,你需要获取的第一个认知就是:在初期95%的竞争中,你碰到的都是配角!

就像宫斗剧里,那些额头贴着“坏蛋”的人,基本一出场,你就能判断这个人活不过两集。他们的存在,就是为了衬托你这个主角的光环。

所以,这个时候,对你来说最重要的,是一边看着其他人犯错,一边偷偷地投资自己,完善自己的能力模型。等一个特定的机会出现的时候,其他人死伤得差不多了,这个时候老板掐指一算,谁有本事去领这个事,结果你在还活着的人里排第一,就算老板之前没宠幸过你几次,他也会选你。

选了你,你的机会就来了,你的台阶就上去了,你就进入下一个战斗区了。之前的那些所谓对手,斗死斗活,都跟你不在一个层面竞争了。这,就是最基础的职场真相。

所以,如何找准自己的能力模型定位,如何比别人先一步看到机会,如何在机会出现的时候稳准狠地拿下,这才是混职场的核心。那些人际关系的小套路,那些周几找老板谈加薪的小技巧,你会,更好;不会,也不耽误大事。

转载自:https://mp.weixin.qq.com/s/_nLfS7LpMU_QB_waodPP0A

Oracle EBS中快速查看某个请求的Output File或log File等信息(转载)

    项目上,经常有请求报红报黄等问题反映到技术顾问这边,但是由于某些权限的限制,有时候哪怕System Administrator职责也只能看到某个Request信息,但是不能查看它的Output File。用下面这个方法可以很方便地查看请求的输出和日志等信息,甚至不用进系统就可以查看了,只需要一个请求编号就可以:

/* Function: GET_URL
*
* Purpose: Constructs and returns the URL for a Concurrent Processing
*          log or output file.
*
* Arguments:
*  file_type – Specifies the type of file desired:
*       fnd_webfile.process_log = The log of the concurrent process identified  by the parameter ID.
*       fnd_webfile.icm_log     = The log of the ICM process identified by ID.
*                                 Or, the log of the ICM process that spawned
*                                 the concurrent process identified by ID.
*                                 Or, the log of the most recent ICM process
*                                 if ID is null.
*       fnd_webfile.request_log = The log of the request identified by ID.
*       fnd_webfile.request_out = The output of the request identified by ID.
*       fnd_webfile.request_mgr = The log of the concurrent process that ran the request identified by ID.
*       fnd_webfile.frd_log     = The log of the forms process identified by ID.
*       fnd_webfile.generic_log = The log file identified by ID.
*       fnd_webfile.generic_trc = The trace file identified by ID.
*       fnd_webfile.generic_ora = The ora file identified by ID.
*       fnd_webfile.generic_cfg = The config file identified by ID.
*       fnd_webfile.context_file= Applications Context file identified by ID.
*       fnd_webfile.generic_text= Generic file using text transfer mode.
*       fnd_webfile.generic_binary = Generic file using binary transfer mode.
*       fnd_webfile.request_xml_output = The xml output of Concurrent Request.
*
*  id        – A concurrent process ID, concurrent request ID, or file ID
*                 depending on the file type specified.
*              For fnd_webfile.context_file,fnd_webfile.generic_text,
*              fnd_webfile.generic_binary this value is null.
*  gwyuid    – The value of the environment variable GWYUID used in constructing the URL.
*  two_task  – The database two_task, used in constructing the URL.
*  expire_time – The number of minutes for which this URL will remain valid.
*  source_file – Source file name with full patch
*  source_node – Source node name.
*  dest_file   – Destination file name
*  dest_node   – Destination node name
*  page_no     – Current page number
*  page_size – Number of lines in a page
*  Returns NULL on error.  Check the FND message stack.
*/
FUNCTION GET_URL(FILE_TYPE   IN NUMBER,
                 ID          IN NUMBER,
                 GWYUID      IN VARCHAR2,
                 TWO_TASK    IN VARCHAR2,
                 EXPIRE_TIME IN NUMBER,
                 SOURCE_FILE IN VARCHAR2 DEFAULT NULL,
                 SOURCE_NODE IN VARCHAR2 DEFAULT NULL,
                 DEST_FILE   IN VARCHAR2 DEFAULT NULL,
                 DEST_NODE   IN VARCHAR2 DEFAULT NULL,
                 PAGE_NO     IN NUMBER DEFAULT NULL,
                 PAGE_SIZE   IN NUMBER DEFAULT NULL) RETURN VARCHAR2;

 

–调用代码

SELECT FND_WEBFILE.GET_URL(3, –输出类型  
                           523502, –请求编号  
                           'APPLSYSPUB/PUB',
                           'FCWW',
                           10)
  FROM DUAL;

–参数介绍

第一个参数4表示request的output,(可根据需要决定)
/* Define file types for get_url */
process_log constant number := 1;
icm_log constant number := 2;
request_log constant number := 3;
request_out constant number := 4;
request_mgr constant number := 5;
frd_log constant number := 6;
generic_log constant number := 7;
generic_trc constant number := 8;
generic_ora constant number := 9;
generic_cfg constant number := 10;
context_file constant number := 11;
generic_text constant number := 12;
generic_binary constant number := 13;
request_xml_output constant number :=14;

第二个参数是request_id
第三个参数是环境参数GWYUID
第四个参数是two_task,
第五个参数是url有效的分钟数. 
然后就是把这个url复制到ie就可以看到了.

转载自:https://zhangzhongjie.iteye.com/blog/1815442