Tuesday, January 25, 2022

wscript wont launch exe file spaces in path

wscript wont launch exe file spaces in path

Hi

Ive looked around the net for this but nothing thus far works. I have zero knowledge of vbs

I want to execute a bat file via a small vbs script, idea is to launch the bat invisibly, this has worked perfectly until I needed to user a folder path with a space. I'm launching this command from powershell, remote execution tool launches the vbs command.

-k (Command to run)

& .\owexec.exe -c "computer1" -u "contoso\vader" -k "wscript.exe C:\Users\Public\Recorded TV\launchProgram.vbs C:\Users\Public\Recorded TV\Test-wscript.bat"

The space in the \Recorded TV\ section of the file name is the blocker here.

Error: There is no file extension with "c:\users\recorded",

The articles Ive read mention using triple quotes """ Ive tried numerous different combinations but nothing works, So difficult to deal with a simple thing such as a space

on other occasions i get the error?  box   titled "Windows script host settings"

the contents of lsunchProgram.vbs  is

CreateObject("Wscript.Shell").Run """" & WScript.Arguments(0) & """", 0, False

below line with no spaces in the path worked perfectly

& .\owexec.exe -c $computer1 -u $domain\$user1 -k "wscript c:\users\Public\Documents\launchProgram.vbs c:\users\Public\Documents\BATfile.bat" -nowait

Any ideas ?

Thanks

Confuseis


confuseis




  • Edited by confuseis Tuesday, January 31, 2017 9:23 PM
  • Changed type Bill_Stewart Monday, March 6, 2017 7:23 PM
  • Moved by Bill_Stewart Monday, March 6, 2017 7:23 PM This is not support forum for third party software

Reply:

Why?  Just run the program from PowerShell:

Windows will provide the correct equivalent of quoting:

$arguments = @(  	'-c computer1',  	'-u contoso\vader',  	'-k cscript.exe',  	'C:\Users\Public\Recorded TV\launchProgram.vbs',  	'C:\Users\Public\Recorded TV\Test-wscript.bat'  )  Start-Process -FilePath .\owexec.exe -ArgumentList $arguments
We should use "cscript" to execute  vbs files to prevent popups.


\_(ツ)_/


  • Edited by jrv Tuesday, January 31, 2017 9:33 PM

------------------------------------
Reply:
What is 'owexec.exe'? You need to ask the author of that program how to use it properly.

-- Bill Stewart [Bill_Stewart]


------------------------------------
Reply:

owexec is a gem.   This will allow you to remotely run a command under the logged on user context with out needing their password, somethin psexec does not do.  great for hassle free remote administration.  Ive used it without hassle, but wscipts syntax and owexecs syntax may not play well together on this occasion where the space in the file name needs to be resolved.


confuseis


------------------------------------
Reply:
Thanks.   Ive tried that but same deal.  I'm thinking that the usage between owexec and wscript do not play well together when there is a space in the file name to be resolved.   Wonder is there a power shell way of launching bat file invisibly instead ?    ill have a search.

confuseis


------------------------------------
Reply:

start-process test.bat -WindowStyle Hidden   

looks promising


confuseis


------------------------------------
Reply:

This is not a support forum for that program.

Ask the author.


-- Bill Stewart [Bill_Stewart]


------------------------------------

Remove RDP history for all users and not just the current user.

Hi,

is their a way to clear the RDP history for all users, even the ones that have not logged in yet. This would be on a windows 7 OS. 

Thanks,


Bobby

  • Changed type Bill_Stewart Monday, March 6, 2017 7:22 PM
  • Moved by Bill_Stewart Monday, March 6, 2017 7:23 PM User needs to learn how to research properly

Reply:

What do you mean by "clear the RDP history"?

And why?


-- Bill Stewart [Bill_Stewart]


------------------------------------
Reply:

Hi Bill,

I meant the remote desktop connection history, so when a user logs in, they don't see the last user who logged into the remote desktop connection. 

Thanks,

Bobby


------------------------------------
Reply:

Group Policy - Post in GP forum for instructions.


\_(ツ)_/


------------------------------------
Reply:
I meant the remote desktop connection history, so when a user logs in, they don't see the last user who logged into the remote desktop connection.

This illustrates the importance of asking a good/precise question.

The last logon user name on a Windows computer has nothing to do with remote desktop.

Now that we know what the question actually should be, here is how you can research it all by yourself:

http://www.google.com/search?&q=remove+last+logon+name+windows


-- Bill Stewart [Bill_Stewart]



------------------------------------

Configure VPN L2TP ipsec protocol

Topics:

Configure LT2p ipsec connection inside and outside domain

Configure it according to norms.

Create a testdocument

To be continued..

(School project)


Reply:

Have you used your favorite search engine to search for 'Configure LT2p ipsec connection '?  I just did and found a number of TechNet articles that can assist.

https://technet.microsoft.com/en-us/library/ff687761(v=ws.10).aspx

https://msdn.microsoft.com/en-us/library/bb742553.aspx


. : | : . : | : . tim


------------------------------------

Hyper V on Windows 10 fails when trying to create a VM using netboot

I am trying to run Hyper-V on Windows 10 x64 Enterprise to test my task sequences but it seems like it is missing the storage drivers for hyper-V as it cannot find a suitable volume to write the data to.  Has anyone else encountered this?   I can use the same task sequence on a physical machine and it works fine, using same model of computers as the HyperV one.

Thanks

Helen Zander


  • Edited by Z.Wheels Tuesday, January 31, 2017 7:51 PM

VBScript: Starting a PowerShell Command on a remote windows7 system


Hi,

I am trying to complete my huge VBS using this code:

IntErrLevel = WshShell.run("cmd psexec \\TESTPC -s D:\test\batch.bat")

The whole app is written in VBS. This is given. I want to start a *.bat on a remote windows system.

Both OSs are Windows7/Ent/64Bit. PowerShell is installed. I have to use this construction because I need the internal error level of the *.bat. What is totally frustrating: I get no error code or message or something else. What is wrong? Both Windows systems are not member of a windows domain, but they trust each other (configured in both PCs' computer management).

TD

  • Changed type Bill_Stewart Monday, March 6, 2017 7:22 PM
  • Moved by Bill_Stewart Monday, March 6, 2017 7:22 PM This is not a psexec support forum

Reply:

The fact that you are executing a remote batch file using a call to psexec that's wrapped in a VBScript script doesn't make this a scripting question.

This is not a psexec support forum.


-- Bill Stewart [Bill_Stewart]


------------------------------------
Reply:

IntErrLevel = WshShell.run("psexec \\TESTPC -s D:\test\batch.bat")

There is no need for CMD.

Also CMD would need to be done this way:

IntErrLevel = WshShell.run("CND /C psexec \\TESTPC -s D:\test\batch.bat")


\_(ツ)_/


------------------------------------

"mangled EF query"

In a previous thread DBB asked if we could see one of the "mangled EF queries" that was 18k long and took twelve seconds to run, when a fairly simple rewrite ran in 12 milliseconds instead.

Here's a link to the raw query, fwiw, some fields names changed to protect the innocent.

https://www.dropbox.com/s/nkcspmtm03lfkmk/18k%20EF%20Query%20Ex.sql?dl=0

Not sure what one can make of it, except that it does some left joins to some subqueries, and at some point apparently this turns opaque to the compiler/optimizer, and of course the general prolix syntax of everything being doubly or triply aliased.

btw, while this query was "only" about 18k characters, I have some others that are over 200k char, which in nchar is over 400k bytes, for a relatively small amount of data.

Josh

previous thread:

https://social.msdn.microsoft.com/Forums/sqlserver/en-US/54e330d6-3452-4bdb-a4b8-850b19dbf8ca/cpu-and-duration-for-very-long-query-commands?forum=sqldatabaseengine


Reply:

EF is not good for joining tables, for even simple joins. It performs much better if you create a VIEW which returns the columns you want in the way you want and point EF to the view.


------------------------------------
Reply:
Thanks JRStern - I am trying to do a presentation on EF for SQL admins and Developers and I like to see other people's EF.

------------------------------------
Reply:
What kind of presentation this is going to be? I'd like to hear it (and may be our team will be interested as well).

For every expert, there is an equal and opposite expert. - Becker's Law


My blog


My TechNet articles


------------------------------------
Reply:

Hi Tom,

Interestingly this is exactly our solution (which I originally introduced) for the simple lists.


For every expert, there is an equal and opposite expert. - Becker's Law


My blog


My TechNet articles


------------------------------------
Reply:
@Naomi - hopefully a useful one. For a local SQL group or a SQL Sat.

------------------------------------
Reply:

EF is not good for joining tables, for even simple joins. It performs much better if you create a VIEW which returns the columns you want in the way you want and point EF to the view.

Well, that is an interesting proposition.  I suppose using a view is sort of half-way to just using an SP instead - in the case of this 18k one my preferred solution uses two statements, could not easily be done as well in a view, though I might fiddle with it to find out.

What do any EF guys you might talk to, say to your suggestion?

Thanks,

Josh


------------------------------------
Reply:

If it could not be easily done in a view, then it definitely should not be done via code generation in EF.


------------------------------------
Reply:

If it could not be easily done in a view, then it definitely should not be done via code generation in EF.

Doesn't it impugn the capabilities of EF in some ways, if a view "helps", or not?

Josh


------------------------------------
Reply:

EF is not the end all of database access, no mater what MS says.  No code generator will ever create code as efficient as a human.


------------------------------------
Reply:

My take on EF or anything like it, is that we can expect it to work well enough 80% of the time, and it will need some kind of help the other 20% of the time.  That worked well enough in my last project, but on this one they seem to want to stay within EF more strictly.

Josh


------------------------------------
Reply:
EF works ok for single table CRUD operations and selects with 1-2 table joins.  Anything more complicated and EF fails miserably and you will fight performance every step of the way.

------------------------------------
Reply:

Yes. My guidance is to be careful with complicated LINQ to EF queries.  There are a couple of easy techniques EF developers can use to avoid complex queries.

First is to use .Include() sparingly.  You really only want a single .Include path in a query.  Especially avoid multiple 1-many include paths.

eg

from o in db.Orders.Include(o => o.OrderDetails.Product).Include(o => o.Customer)

is ok, since it's just one row per OrderDetail row, with some extra columns joined in.

but

from o in db.Orders.Include(o => o.OrderDetails).Include(o => o.Invoices)

EF will turn this into a wide resultset with |Invoices| * |OrderDetails| rows.

Instead you can explicitly load the Invoices after fetching the Order and OrderDetails, and build up the object graph with a few queries.

If you have a large number of Orders returned you can simply run a query like

List<int> OrderIds = mReturnedOrders.Select(o => o.OrderId).ToList();

db.Invoices.Where( i => OrderIds.Contains(i.OrderID) ).AsEnumerable().Last();


And EF will fetch the related Invoices using a single query for all your orders and "fix up" all the object graphs. 

Another tip is to use an EF LINQ query to fetch the rows you are interested in, and then use a LINQ to Objects for subsequent processing.  You can simply introduce a ToList() or AsEnumerable() to signal the end of the EF query operations, and the start of the in-memory operations.

Another tip is to set UseDatabaseNullSemantics=true.  Without this EF has to generate TSQL queries that emulate C# null comparison semantics (eg (null==null)=true), which complicates the query generation and can impact performance.

Another tip is to avoid explicit joins in LINQ to EF.  They are almost never necessary, as you can simply traverse your Navigation Properties, and they are a big "red flag" for a query becoming overly complicated. 

David


Microsoft Technology Center - Dallas

My Blog






------------------------------------
Reply:

Thanks David and everyone, we're going to process a couple of these runaway EF statements on our next sprint, and I hope this will help everyone understand the best practices.

Josh


------------------------------------
Reply:

Hi David,

I have a question. We have the following generic method in our base class repository 

public virtual T GetById(object id)       

{            return _dbSet.Find(id);        }

Suppose my model class has related entities, e.g. 

 // Reverse navigation   public virtual System.Collections.Generic.ICollection<EventListenersOperatorLink> EventListenersOperatorLink { get; set; } // EventListeners_OperatorLink.FK_EventListeners_OperatorLink_EventLstId


I created a ViewModel where I have 

 public IEnumerable<EventListenersOperatorLink> SelectedOperators { get; set; }


My question is - what is the best and simplest method to get these related Operators? In other words, right now I have the following in my GetById API Controller's method:

[Route("{id}")]   public IHttpActionResult GetOperatorsNotification(long id)   {   EventListeners operatorsNotification = _operatorsNotificationAdapter.GetById(id);   if (operatorsNotification == null)   operatorsNotification = new EventListeners();     var operatorsNotificationViewModel = AutoMapperConfig.Mapper.Map<EventListeners, EditOperatorsNotificationViewModel>(operatorsNotification);   SetViewModel(operatorsNotification.ActivType, operatorsNotificationViewModel);   return Ok(operatorsNotificationViewModel);   } 

where adapter just calls the repository GetById method.

I want to get these related operators as well - what is the best way?

Thanks in advance.

UPDATE. I implemented it this way in the repository:

public override EventListeners GetById (object Id)   {   int id = Convert.ToInt32(Id);   EventListeners notification = this._dbSet.AsQueryable().Where(s => s.EventLstId == id).Include(e => e.EventListenersOperatorLink).FirstOrDefault();   return notification;   }

Does it look OK to you?


For every expert, there is an equal and opposite expert. - Becker's Law


My blog


My TechNet articles



  • Edited by Naomi N Tuesday, January 31, 2017 7:27 PM

------------------------------------

Deletion of the duplicates in Excel file using Powershell

Hello,

Could you please give me a hand with the deletion of the duplicates in Excel file? I need to choose two columns. My file contains headers. How can I do that with Powershell?

Many thanks.


Reply:

------------------------------------
Reply:

------------------------------------
Reply:
Here is another good place to ask Excel questions: https://answers.microsoft.com/en-us/msoffice/forum/msoffice_excel

\_(ツ)_/


------------------------------------
Reply:
Thanks but the easiest method is using GUI (I know it) and I'm searching for the Powershell solution and I thinks as it's Powershell involved it's not purely Excel question.

------------------------------------
Reply:

Then you need to post you Excel portion of the script as your question is too vague.

Excel has  button that will remove all duplicates in a range.  Is that what you are trying?


\_(ツ)_/


------------------------------------
Reply:

------------------------------------
Reply:

My question is not vague, I guess. It's direct. I need to do that by Powershell, not by button. I know how to do that using GUI buttons. The thing is I need to do that using Powershell to put it in my script and I couldn't find anything useful via Google. Also I don't know C#. Nothing to post really as I have no any idea how to do that so nothing to post anyway... Sorry. It should some simple one or two string command. Simply I don't know it. I need to delete duplicates. If the values of two fields in a row in an Excel file match then I need to delete one row out of the two.

Something like that but using Powershell.

http://www.excel-easy.com/examples/remove-duplicates.html


  • Edited by AzatM Sunday, January 22, 2017 6:01 PM

------------------------------------
Reply:

There is a method called RemoveDuplicates but it is buggy in PowerShell.

You can use Excel from PowerShell to enumerate the rows and detect duplicates. Use a Dictionary to find rows that are already seen.  Delete as  you go.

Your question is vague because "duplicates" is not defined. Duplicate what?

Here is a good starter for how to use Excel with PowerShell: https://theolddogscriptingblog.wordpress.com/2010/06/01/powershell-excel-cookbook-ver-2/


\_(ツ)_/


------------------------------------
Reply:
I've given you a link above so that you could understand what "duplicates" I meant. IN terms of Excel it is not a vague.

------------------------------------
Reply:

So you want to remove duplicate cells?  Just add all of the cells to a dictionary by cell value then remove all of the cells in each collection except one.

You cam also use "Find to fin matching cells in a forward direction and remove any found.  What you need to do is vague as there are many,. many ways to define what is duplicated and how you would detect that.

Ok - I looked the link. You want to remove duplicate rows. Works the same way but you have to enumerate the rows then scan all future rows and match the two.

Search - there are a number of PowerShell examples on the net and in the Gallery.


\_(ツ)_/


------------------------------------
Reply:
$xl = New-Object -ComObject Excel.Application  [void]$xl.Workbooks.Open('D:\test4\Book2.xlsx')  $xl.Visible = $true  $r = $xl.Workbooks[1].Worksheets[1].UsedRange  $cols = [object[]]@(1,2)  $r.RemoveDuplicates($cols,2)  

Her is a PowerShell method but it won't work with all examples due to some bugs in the way PowerShell addresses the Interop.


\_(ツ)_/


------------------------------------
Reply:

Thanks. Seems like worked this out using the following code:

   $csv = import-csv -path "$PSScriptRoot\$($file.name)" -Delimiter ";"

    $arr  = @()
    $tarr = @()
    
    ForEach ($c in $csv)
    
    {
    
        if ($tarr -notcontains "$($c.host)$($c.MSSQL_CI_name)")
    
        {
        $arr  += @($c)
        $tarr += @("$($c.host)$($c.MSSQL_CI_name)")
        }
    }

    $arr | Export-Csv -Path "$PSScriptRoot\$($file.name)" -delimiter ";" -NoTypeInformation


------------------------------------

Keyboard problem top numbers not working only 5,6 and FN

How to fix this? i have this problem like 1,2 months cannot really remember..... I tried everything but i need your help :P

Reply:

I meant FN not working too.. I tried AltGR+Ctrl+FN but not working

I even tried reinstalling keyboard but nope

Everything i tried is not working


------------------------------------
Reply:
This is a laptop?  It sounds like a probable hardware failure.  In the shop I would verify that by booting an alternative Operating System or a tool like a Windows repair media and test typing in a command prompt or elsewhere.  You might also plug in an external keyboard and see if that works normally.

------------------------------------

In SSRS Report's using MDX Quary's how to handle Between operator,i want to get data b/w the fromdate and todate parameter but it is not working,how to slove?

 Working Only matching dates (EX:select "26/11/2016" showing data,if we select "27/11/2016" or "25/11/2016" not showing data 

SELECT NON EMPTY { [Measures].[LeadCount] } ON COLUMNS, NON EMPTY { ([DimAccount].[Industry].[Industry].ALLMEMBERS * [DimAccount].[CreatedDate].[CreatedDate].ALLMEMBERS ) } DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_VALUE, MEMBER_UNIQUE_NAME ON ROWS FROM ( SELECT ( STRTOMEMBER(@FromDimAccountCreatedDate) : STRTOMEMBER(@ToDimAccountCreatedDate) ) ON COLUMNS FROM [ClientCursor]) 


Reply:
The query itself appears correct, and MDX's range operator (semicolon) is the rough equivalent of SQL's between. You should capture the queries that are generated when parameters are replaced by their actual values. Either the query's text will show up wrong, which means you troubleshoot parameters, or the cube will return unexpected data for a correct query, which means you troubleshoot the cube.

Expect me to help you solve your problems, not to solve your problems for you.


------------------------------------
Reply:

There are a couple of things that might snag you.

  1. The two dates need to exist in the dimension. If one doesn't exist, you could switch it with NULL, which would be the very beginning or very end.
  2. The parameter from RS really should be the fully qualified date member. Are they? Or are they simply the dates? You can connect a dimension to RS and use the fully qualified member keys. What some developers do is to have RS just pass the raw key, and concatenate this with the qualifier in the MDX query. Such as STRTOMEMBER("[MyDateDim].[MyDateHierarchy].&[" + @RSParameter + "]"). Just an idea, I'm not necessarily suggesting it.

One way to ascertain exactly what the issue is would be to capture the query with SQL Profiler. That's what I would do.

Hope that helps,


Richard


------------------------------------
Reply:

if i pass From date as "26/11/2016"  and to date as "29/12/2016" then data is coming from 26 th and 29 th only,but i want data in between entire data "25th to 29 th Nov" .

SELECT NON EMPTY { [Measures].[LeadCount] } ON COLUMNS, NON EMPTY { ([DimAccount].[Industry].[Industry].ALLMEMBERS *
 [DimAccount].[CreatedDate].[CreatedDate].ALLMEMBERS ) } 
DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_VALUE, MEMBER_UNIQUE_NAME 
ON ROWS FROM ( SELECT ( STRTOMEMBER(@FromDimAccountCreatedDate) : STRTOMEMBER(@ToDimAccountCreatedDate) ) ON COLUMNS FROM [ClientCursor])
 CELL PROPERTIES VALUE, BACK_COLOR, FORE_COLOR, FORMATTED_VALUE, FORMAT_STRING, FONT_NAME, FONT_SIZE, FONT_FLAGS

<Parameters xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:schemas-microsoft-com:xml-analysis">
        <Parameter>
          <Name>FromDimAccountCreatedDate</Name>
          <Value xsi:type="xsd:string">[DimAccount].[Datecreated].&amp;[20161126]</Value>
        </Parameter>
        <Parameter>
          <Name>ToDimAccountCreatedDate</Name>
          <Value xsi:type="xsd:string">[DimAccount].[Datecreated].&amp;[20170128]</Value>
        </Parameter>
      </Parameters>

<PropertyList xmlns="urn:schemas-microsoft-com:xml-analysis">

     <Catalog>ClientCursor</Catalog>

    <LocaleIdentifier>1033</LocaleIdentifier>

      <Format>Tabular</Format>

  <Content>SchemaData</Content>

 <Timeout>0</Timeout>

  <ReturnCellProperties>true</ReturnCellProperties>

  <DbpropMsmdFlattened2>true</DbpropMsmdFlattened2>

   <DbpropMsmdActivityID>cb3c7237-8edf-484a-b1e5-5354076e87db</DbpropMsmdActivityID>

    <DbpropMsmdCurrentActivityID>cb3c7237-8edf-484a-b1e5-5354076e87db</DbpropMsmdCurrentActivityID>

 <DbpropMsmdRequestID>f74824bd-0651-4cd5-af15-7a18faffee0c</DbpropMsmdRequestID>

 </PropertyList>
-------------------------------------------------------------------------------------------------------------------

SELECT NON EMPTY { [Measures].[LeadCount] } ON COLUMNS, NON EMPTY { ([DimAccount].[Industry].[Industry].ALLMEMBERS * [DimAccount].[CreatedDate].[CreatedDate].ALLMEMBERS ) } DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_VALUE, MEMBER_UNIQUE_NAME ON ROWS FROM ( SELECT ( STRTOMEMBER(@FromDimAccountCreatedDate) : STRTOMEMBER(@ToDimAccountCreatedDate) ) ON COLUMNS FROM [ClientCursor]) CELL PROPERTIES VALUE, BACK_COLOR, FORE_COLOR, FORMATTED_VALUE, FORMAT_STRING, FONT_NAME, FONT_SIZE, FONT_FLAGS

<Parameters xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:schemas-microsoft-com:xml-analysis">
        <Parameter>
          <Name>FromDimAccountCreatedDate</Name>
          <Value xsi:type="xsd:string">[DimAccount].[Datecreated].&amp;[20161125]</Value>
        </Parameter>
        <Parameter>
          <Name>ToDimAccountCreatedDate</Name>
          <Value xsi:type="xsd:string">[DimAccount].[Datecreated].&amp;[20170128]</Value>
        </Parameter>
      </Parameters>

<PropertyList xmlns="urn:schemas-microsoft-com:xml-analysis">

    <Catalog>ClientCursor</Catalog>

 <LocaleIdentifier>1033</LocaleIdentifier>

    <Format>Tabular</Format>

     <Content>SchemaData</Content>

   <Timeout>0</Timeout>

  <ReturnCellProperties>true</ReturnCellProperties>

 <DbpropMsmdFlattened2>true</DbpropMsmdFlattened2>

  <DbpropMsmdActivityID>6eb16625-0bf3-49ef-80ef-0d53e98a038a</DbpropMsmdActivityID>

    <DbpropMsmdCurrentActivityID>6eb16625-0bf3-49ef-80ef-0d53e98a038a</DbpropMsmdCurrentActivityID>

   <DbpropMsmdRequestID>9b042665-d22f-4eb7-b6f4-6dabd37a624b</DbpropMsmdRequestID>

    </PropertyList>

                                                                                                                                                        

------------------------------------

One package in Distribution Point fails with status: Report status message 0x4000094C to MP

We have a strange problem in one sccm site. One specific package fails on reporting its status to Management Point. In the Distribution Point smsdpmon.log there are messages for report status like this:

Package 001000EB is verified successfully	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.19	2740 (0x0AB4)  Report state message 0x40000950 to MP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.19	2740 (0x0AB4)  Report Body: <ReportBody><StateMessage MessageTime="20170128004119.000000+000" SerialNumber="2"><Topic ID="001000EB" Type="901" IDType="0"/><State ID="2384" Criticality="0"/><UserParameters Flags="0" Count="2"><Param>001000EB</Param><Param>["Display=\\dp-fdqn.com\"]MSWNET:["SMS_SITE=001"]\\dp-fdqn.com\</Param></UserParameters></StateMessage></ReportBody>  	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.19	2740 (0x0AB4)  In SSL, but with no client cert	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.19	2740 (0x0AB4)  Report status message 0x40000950 to MP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.22	2740 (0x0AB4)  In SSL, but with no client cert	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.22	2740 (0x0AB4)  Status message has been successfully sent to MP from remote DP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.24	2740 (0x0AB4)  Start to evaluate package '00100057' version 0 ...	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.24	2740 (0x0AB4)  Report status message 0x4000094C to MP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.24	2740 (0x0AB4)  In SSL, but with no client cert	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.24	2740 (0x0AB4)  Status message has been successfully sent to MP from remote DP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.26	2740 (0x0AB4)  Start to evaluate package share for package '00100057' version 0 ...	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.52	2740 (0x0AB4)  Package 00100057 is verified successfully	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.52	2740 (0x0AB4)  Report state message 0x40000950 to MP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.52	2740 (0x0AB4)  Report Body: <ReportBody><StateMessage MessageTime="20170128004152.000000+000" SerialNumber="0"><Topic ID="00100057" Type="901" IDType="0"/><State ID="2384" Criticality="0"/><UserParameters Flags="0" Count="2"><Param>00100057</Param><Param>["Display=\\dp-fdqn.com\"]MSWNET:["SMS_SITE=001"]\\dp-fdqn.com\</Param></UserParameters></StateMessage></ReportBody>  	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.52	2740 (0x0AB4)  In SSL, but with no client cert	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.52	2740 (0x0AB4)  Report status message 0x40000950 to MP	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.54	2740 (0x0AB4)  In SSL, but with no client cert	SMS_Distribution_Point_Monitoring	28.1.2017 11.11.54	2740 (0x0AB4)  

Weird thing is that no other errors are available in the Distribution Point logs. After the Distribution Point informs the succeeded package update and tries to send its status to Management Point, nothing happens in the Site Server. It takes something like 40 minutes and after that the package is a failure, when looking from the Config Mgr console. Even that is the status, there are indeed package .ini-file and package under the SCCMContentLib (PkgLib contains the relevant .ini).

Other packages are succeeding to this Distribution Point, no problem there. What we already tried is: remove the package from DP (no help), updating the package (no help), redistributing the package (no help) and of course we made a new package with same content and it ends on same status. This package is working on other DPs (nearly 20 other DPs), only one DP is failing to reporting package status to DP.

Any idea what is going on with this package?


Reply:

PkgXFerMgr.log gives some more information about the problem:

VerifyContentHash() failed. Error = 0x80010108  CSendFileAction::SendContent failed; 0x80010108   Sending failed. Failure count = 20, Restart time = 31.1.2017 14:10:09 FLE Standard Time


------------------------------------

SharePoint 2013 Search: BCS Crawl Error - Error while crawling LOB contents.

Hi,

1. I have created BCS Service in SharePoint 2016 Server using farm account.

2. I created External content type in designer.
3. Create content source for the BCS in search service application.
4. I have did Full crawl BCS content source but crawling is failing. i got below error message like"Error while crawling LOB contents".
I checked in ULS log i found below error.

bdc3://local/Default/00000000%2D0000%2D0000%2D0000%2D000000000000&s_ce=042000204080g00Use SHIFT+ENTER to open the menu (new window).
Error while crawling LOB contents. ( Error caused by exception: System.ServiceModel.ProtocolException An error occurred. Administrators, see the server log for more information.; SearchID = A021D6F9-2B39-4477-9FFD-673FA1FAF81F )<o:p></o:p>

So please help us to fix this issue.

Regards,

Bhaskar.


Opening a link to an outside server

hello, 

I downloaded Microsoft Remote Desktop in hopes of opening <g class="gr_ gr_47 gr-alert gr_gramm gr_disable_anim_appear Grammar multiReplace" data-gr-id="47" id="47">a outside</g> server link sent from my employer. How do I go about this?


Reply:
Looks like TechNet has corrupted your post. Can you repost or describe your issue? Thank you.

------------------------------------

New resolutions not enabled on upgrade to Mac RDP 8.0.37

RDP 8.0.37 for Mac mentions in the release notes that it supports new resolutions. However, I could not see any new resolutions in the properties of the existing connections. Then I went to Preferences->Resolution and clicked on Defaults. The list of resolutions became much longer. I believe the new resolutions should be enabled automatically. There is nothing wrong with adding all newly supported resolutions to the list on upgrade. Users can always delete unneeded resolutions if they don't like the long list. Maybe RDP 8.0.38 could do it?


Reply:

HI Pavel,

thank you for reporting this to us.

We will be working on that issue for 8.0.38. In the meantime to  get the full list go to Preferences -> Resolutions -> Click defaults. You can reset the resolutions and press defaults. Note: this will delete any custom resolutions you might have entered.

Eva


------------------------------------

SfB 2015 Meeting Room PC's

We are using Skype for Business 2015 (hosted in Office 365). Colleagues currently have their own devices but we have installed Skype for Business on some PC's in our meeting rooms. We ideally would like colleagues to log onto the PC's and SfB automatically signing in with that room name.  We have set these up in but normally require a domain log on. Can we set these PC's up so that they use a Skype for Business Room log on if that makes sense?

Reply:

You can do the following - Create room mailboxes and enable those accounts for Skype for Business. Lock down the boardroom PCs with Kiosk mode or something similar and instruct users to create Skype for Business meetings when inviting the boardroom. That way you they can join the meeting from the boardroom PC.

Now a bit of advice from personal experience - This roll out seems simple enough - get skype client installed, have users invite the room and it will work as expected right?  - WRONG!  Lock down the boardroom PCs and the cables connecting them, otherwise prepare to face a barrage of 'THE MEETING ROOMS ARE DOWN  AND OUR MEETING IS STARTING NOW, SKYPE FOR BUSINESS SUCKS!' type of tickets going forward.

This might sound jaded, but trust me - no matter how much you trust your users they will look for someone to be at the end of their pitchforks when their meeting is late before the person before them unplugged the network cable/shut off the TV/took out the batteries from the keyboard. Make those things childproof!

If you insist on having your own hacked solution (custom windows install and the skype for business client) that will work, but make absolutely sure you lock that device down, else you risk find webex/regular skype/ and other software installed on it and god forbid that client runs in the background and hogs the camera/audio while an exec comes in to attempt to have a Skype for Business meeting. In addition communicate clearly the requirements and instructions for users to operate these rooms successfully. Schedule some training as well.

If you have budget I'd highly recommend you get something like this: http://www.logitech.com/en-ca/product/smartdock , or the Microsoft equivalent when they come out with it.

We've tested a ton of devices, Vyutru, the logitech box, microsoft smart systems, custom built solutions and in all cases the above advice (locking down cables and making the solution basically childproof) as well as allocating adequate bandwidth for the units is an absolute requirement for the success of these roll-outs.


Good luck.

Max


  • Edited by Maxim M Monday, January 30, 2017 8:45 PM

------------------------------------

What is the best possible way to organize OpenXML trickle feed data?

I am attempting to solve for multiple imports of OpenXML messages which will be trickling into a set of staging tables. The messages are mid-size (4K-5K bytes per message), arriving from 500 different sources. This process will be ongoing, 24/7. From this set of staging tables,  the data will be further transformed, then shredded and inserted into corresponding tables which will constitute the desired final output.  Once the data is available in it's final output schema, it will be read by other feeder processes.

I have a much smaller version of a similar process active currently in production without battling such issues as bottlenecks, deadlocks, etc. However, I think this process requires much more consideration to both.

Please offer your thoughts on how best to organize and process this data--this includes approaching the processing of incoming data into staging as well.


paula.ditallo@outlook.com

  • Changed type Lin LengMicrosoft contingent staff Tuesday, January 31, 2017 7:55 AM more discussion than question
  • Moved by Olaf HelperMVP Saturday, February 18, 2017 8:01 AM Moved from "Database Engine" to a more related forum for a better response

Having An Issue With PS1 To Find String & Use To Rename File

I have the PS1 below - it does not throw any errors in debug or run, but doesn't do the rename of the file I'm looking for.

$files = ((Get-ChildItem $dir).Name -like "hsbc_fr*.txt")    foreach ($file in $files)    {$val1=(Get-Content $file | Select-String -Pattern "EUR")    $newname = $val1 + "FRANCE" + ".txt"    Rename-Item $file -newname $newname}

Script dips into the file and finds string EUR, then use that to rename the file to "EURFRANCE.txt" 

Confused since no errors show up - so what am I missing?


Reply:

Start by formatting you code correctly:

$files = (Get-ChildItem $dir).Name -like 'hsbc_fr*.txt'  foreach ($file in $files) {  	$val1 = Get-Content $file | Select-String -Pattern 'EUR'  	$newname = "$val1FRANCE.txt"  	Write-Host $newname -fore green  	Rename-Item $file -newname $newname -Verbose  }


\_(ツ)_/


  • Edited by jrv Monday, January 30, 2017 7:19 PM

------------------------------------

Powershell to move many Windows hosts to new domain.

Was curious how difficult it would be to run a script referencing a list of servers to remove the hosts from their current domain into the Workgroup, reboot, and then join them to a new domain.  I think you can push these types of changes via security/group policy, but I don't have access to those resources.  My goal is to migrated around 200 hosts to a new domain.
  • Changed type Bill_Stewart Monday, March 6, 2017 7:19 PM
  • Moved by Bill_Stewart Monday, March 6, 2017 7:20 PM Unanswerable drive-by question

Reply:

Not too difficult if you are familiar with basic PowerShell principles.

Pretty difficult if you're not familiar with basic PowerShell principles.


-- Bill Stewart [Bill_Stewart]


------------------------------------
Reply:

------------------------------------

Credential Guard and Hypervisor enforced Code Integrity no longer working after cumulative update KB3206632

After applying KB3206632 from the December patch day credential guard and HECI do no longer work.

From msinfo32:

"Device Guard Virtualization based security    Enabled but not running
Device Guard Required Security Properties     Base Virtualization Support, Secure Boot, DMA Protection
Device Guard Available Security Properties     Base Virtualization Support, Secure Boot, DMA Protection
Device Guard Security Services Configured     Credential Guard, Hypervisor enforced Code Integrity
Device Guard Security Services Running         "

In the system log an Event ID 124 from Kernel-Boot is stating: "The Virtualization Based Security enablement policy check at phase 0 failed with status: The volume for a file has been externally altered such that the opened file is no longer valid."

In Application_Microsoft_Windows_Kernel-Boot_Operational are two entries:

Event ID 43: "Windows failed to import ExAllocatePoolWithQuotaTag from image cng.sys with error status 0xC0000098."

Event ID 42: "Windows failed to load image \SystemRoot\system32\securekernel.exe imported from cng.sys with error status 0xC0000098."

As cng.sys has been updated by KB3206632 I assume that something went wrong w/ that file.

The file is signed by Microsoft:

> sigcheck -nobanner C:\Windows\System32\drivers\cng.sys
c:\windows\system32\drivers\cng.sys:
        Verified:       Signed
        Signing date:   11:18 09.12.2016
        Publisher:      Microsoft Windows
        Company:        Microsoft Corporation
        Description:    Kernel Cryptography, Next Generation
        Product:        Microsoft« Windows« Operating System
        Prod version:   10.0.14393.576
        File version:   10.0.14393.576 (rs1_release_inmarket.161208-2252)
        MachineType:    64-bit

The OS is Windows 10 Enterprise x64 Eng. Build 14393.576.

Before that update CG and HECI were working w/o issues.

Does anybody else has the same issue?


  • Edited by JSp42 Wednesday, December 14, 2016 1:40 AM added sigckeck output

Reply:

I have the same issue with credential guard not working after installation of KB3206632. If I uninstall the update credential guard works again.

 


------------------------------------
Reply:

Which gives us (thanks to the cumulative bundles) the option to remove the update including all security fixes to get the VBS again or keep the security updates but loose the security benefits of CG and HECI.

Either way we loose (some security).


------------------------------------
Reply:

Exactly. I hope there will be a solution/fix real soon that are at least somewhat tested before released. I have a number of computers with the issue.

It's ironic that a security update breaks security....


------------------------------------
Reply:
I had the same problem, and uninstalling KB3206632 fixed it.

------------------------------------
Reply:

Event ID 124 from Kernel-Boot is stating: "The Virtualization Based Security enablement policy check at phase 0 failed with status: The volume for a file has been externally altered such that the opened file is no longer valid."

Will there be a fix?

Answer:  Yes

[–]johnwinkmsftSoftware Engineer[S] [score hidden] <time class="live-timestamp" datetime="2016-12-14T21:03:30+00:00" title="Wed Dec 14 21:03:30 2016 UTC">3 hours ago</time> (0 children)

From:

https://www.reddit.com/r/Windows10/comments/5i57fr/december_windows_10_cumulative_updates_kb3206632/



------------------------------------
Reply:
KB3213522 seems to restore VBS functionality. Credential Guard is working again after installation of KB3213522.

------------------------------------
Reply:
Does KB3213986 install the fix in KB3213522?

Hope this helps, Gerry


------------------------------------

WSUS Product Suggestion

This is a long story, but the background is needed to understand the product requests/suggestions. I don't know if Microsoft WSUS developers read this forum often, but it is my hope.



My group manages over 1,000 Windows servers. We manage systems for a large number of departments and applications. Business and regulatory requirements dictate the use of a number of different outage windows for patching that are often very short. WSUS is an ideal tool for this use. We utilize the deadline feature with computer groups in order to fine tune the time/date window for the myriad patch schedule requirements. We also have requirements to apply or restrict certain patches to specific groups or systems.  The downside to this is that over time the number of groups (150+) and schedules have grown greatly and now take a significant amount of time to get set properly. We normally apply patches from the previous three months in order to catch systems that may have skipped a month or two because of business requirements.



One particular issue we run into is when a server admin installs something that triggers certain patches that are outside our three month window. This necessitates going back and scheduling additional patches on an ad-hock basis. This just adds to the already large burden.  



Now comes my thoughts/suggestions.

After applying a patch schedule I run "Updates Needed" reports against systems to look for patches that are needed, but not scheduled. I then click the link in the approval column to set the schedules against groups. This is a "one at a time" process that can sometimes take hours to accomplish. It occurred to me that this process could be made much easier by having check boxes next to each listed patch within the report so that several could be selected and scheduled together.



Next suggestion. When approving sets of updates in the Updates node a schedule needs to be set for each individual computer group. It would be really nice to be able to select a configuration file that supplies the schedule settings for each of the groups. This is very repeatable and less prone to keyboard mistakes. 



Some of you might respond with "use PowerShell". Unfortunately the available WSUS PowerShell commandlets are much too limited to allow these fine tunes processes. We have spent lots of time trying.



Thank you for reading. 



Reply:

Hi SGould,

Thanks for your feedback and valuable suggestions, since this post is more related about suggestions, not for a specific question, I would change its type to "General discussion".

For your information.

Best Regards,

Anne


Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.


------------------------------------
Reply:
Thank you for your suggestion.

------------------------------------

The best book to learn T-sql

Hi to all Members 

What is the best book to learn T-sql?

THANKING YOU IN ADVANCE




Reply:

These threads have a long list of sites and book references:

https://social.msdn.microsoft.com/Forums/sqlserver/en-US/20f6db70-70de-4e14-8c11-3d8947eab324/best-site-for-learn-tsql-on-sqlserver-?forum=transactsql

https://social.msdn.microsoft.com/Forums/sqlserver/en-US/2f32d5e1-de7f-4bec-a8bf-039b9662b331/learning-t-sql?forum=transactsql

Thanks,
Sam Lester (MSFT)


https://blogs.msdn.microsoft.com/samlester/

Twitter - @SQLSamLester

This posting is provided "AS IS" with no warranties, and confers no rights. Please remember to click "Mark as Answer" and "Vote as Helpful" on posts that help you. This can be beneficial to other community members reading the thread.


------------------------------------
Reply:

There are lots of books and online resources available to help you learn TSQL. One of my favorite books is TSQL Fundamentals by Itzik Ben-Gan.

A good online resource is Microsoft Virtual Academy.

Good Luck,


Phil Streiff, MCDBA, MCITP, MCSA


------------------------------------
Reply:

Hi Arab,

Refer following link.

https://www.sqlservercentral.com/Forums/Topic1127657-392-1.aspx

https://blogs.msdn.microsoft.com/microsoft_press/2016/04/08/simple-talk-awards-tsql-best-database-book/


Please Mark it as Answered if it answered your question OR mark it as Helpful if it help you to solve your problem.


------------------------------------
Reply:

Specifically for the T-SQL dialect, I recommend:

https://www.amazon.com/T-SQL-Fundamentals-3rd-Itzik-Ben-Gan/dp/150930200X/ref=pd_sbs_14_t_0?_encoding=UTF8&psc=1&refRID=FY6J6FDQNHJ30DGRRP5W

The "mere mortals" series is also good.

It will also help if you will actually learn SQL as opposed to a dialect. This is why I do not recommend my own books to beginners; they tend to be generic SQL and a bit more advanced than someone just learning the language. This is testimony against interest, since I would really like the royalty money :-)



--CELKO-- Books in Celko Series for Morgan-Kaufmann Publishing: Analytics and OLAP in SQL / Data and Databases: Concepts in Practice Data / Measurements and Standards in SQL SQL for Smarties / SQL Programming Style / SQL Puzzles and Answers / Thinking in Sets / Trees and Hierarchies in SQL


------------------------------------
Reply:
Thank you for your help

------------------------------------
Reply:

Thank you for your help


------------------------------------
Reply:
thank you very much

------------------------------------

No comments:

Post a Comment

Setup is Split Across Multiple CDs

Setup is Split Across Multiple CDs Lately I've seen a bunch of people hitting installation errors that have to do with the fact th...