Reindexing / rebuild Indexes on Linked Server tables
Four-part-naming syntax is not supported for ALTER INDEX.

Try this:

EXEC ('ALTER INDEX ALL ON [dbname].[dbo].[tablename] REBUILD WITH (FILLFACTOR = 90);') 
AT LinkedServerName;