由于假冒错误(外卡支持),Oozie作业无法运行

时间:2016-06-12 12:36:00

标签: hadoop oozie

尽管设置了用户" kapil.sharma02"我无法在本地单节点hadoop群集上运行oozie作业。作为代理用户。这是由于我的用户名中的外卡吗?你能建议一个补救措施吗?

kapil.sharma02 $ ./oozie job -oozie http://localhost:11000/oozie -config ../examples/apps/map-reduce/job.properties -run

错误:E0501:E0501:无法执行授权操作,用户:kapil.sharma02不允许冒充kapil.sharma02

这是我的core-site.xml(hadoop 2.6.4) 我试过添加这个配置有无转义字符,但没有运气。

BEGIN
SET NOCOUNT ON;
DECLARE @id uniqueidentifier
DECLARE @email nvarchar(256)
DECLARE @emailconfirmed bit
SET @emailconfirmed = 0
DECLARE @twofactorenabled bit
SET @twofactorenabled = 0
DECLARE @lockoutenabled bit
SET @lockoutenabled = 1
DECLARE @accessFailed bit
SET @accessFailed = 1
DECLARE @username nvarchar(256)
DECLARE @fname nvarchar(50)
DECLARE @lname nvarchar(50)

DECLARE @athleteKey int
SET @athleteKey = 41809

DECLARE @atheletsCount int
SET @atheletsCount = 0;
SET @atheletsCount = (SELECT COUNT(*) FROM [BIBD].[dbo].[Athlete])

WHILE @athleteKey < @atheletsCount
    SET @id = NEWID() --Line 36
    print CAST(@id AS nvarchar(128))
    SET @fname = (SELECT FirstName FROM [BIBD].[dbo].[Athlete] where AthleteKey=@athleteKey)
    SET @lname = (SELECT LastName FROM [BIBD].[dbo].[Athlete] where AthleteKey=@athleteKey)
    SET @username = CONCAT(LOWER(@fname),'.',LOWER(@lname))
    SET @email = CONCAT(LOWER(@fname), '.', LOWER(@lname), '@gmail.com')

    INSERT INTO [MyDatabase].[dbo].[AspNetUsers]
       (Id
       ,Email
       ,EmailConfirmed
       ,[TwoFactorEnabled]
       ,LockoutEnabled
       ,AccessFailedCount
       ,UserName
       ,FirstName
       ,LastName)
     VALUES
           (CAST(@id AS nvarchar(128))
           ,@email
           ,@emailconfirmed
           ,@twofactorenabled
           ,@lockoutenabled
           ,@accessFailed
           ,@username
           ,@fname
           ,@lname)

    IF @athleteKey % 5 = 0
        INSERT INTO [MyDatabase].[dbo].[AspNetUserRoles]
                    (UserId,RoleId) VALUES (@id, 3)
    ELSE
        INSERT INTO [MyDatabase].[dbo].[AspNetUserRoles]
                    (UserId,RoleId) VALUES (@id, 4)

    SET @athleteKey = @athleteKey+1
END

1 个答案:

答案 0 :(得分:0)

您能否查看您的工作日志以获取正确的故障信息。我不确定这是否对您有所帮助,但类似问题已得到解决here。请看看。